Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <string.h>
- int main(void)
- {
- int flag = 0;
- char passwd[45];
- fgets(passwd, 45, stdin);
- printf("Checking password... Please wait.");
- char secret_code[] = "hunter2\n";
- if(0 == strcmp(secret_code, passwd))
- flag = 1;
- printf(passwd);
- if(flag) printf(" is correct :D");
- else printf(" is incorrect :(");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement