This article is a little bit of information you share: Analog Bank input Password source + comment + Solution!
Input of the analog password
Library 1: * * *
Library 2: Automatic submission of in place
Network API Details 800 page
Learning Network Concept Library
C Data Structure Linux
C + + data structure Windows QT MFC
8000
#include
#include
#include//getch no echo getchar Echo
int main ()
{
Char passwd[] = "123456"; Original password
Char in[12] = {0}; Save the entered password
Char ch;
int i = 0;
printf ("Enter password \ n");
while ((ch = getch ())! = ' \ R ')//enter \ r \ n
{
if (ch = = ' \b ')
{
printf ("\b \b");
In[i] = ' + ';
i--;
}
Else
{
printf ("%c", ' * ');
In[i] = ch;
i++;
}
}
if (strcmp (passwd,in) = = 0)
{
printf ("\ n password entered correctly \ n");
//...
}
Else
{
printf ("\ n password is incorrect \ n");
}
return 0;
}
C Language Tutorial Analog bank input password source code