Advertisement
Guest User

Untitled

a guest
Dec 12th, 2019
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. #include <stdlib.h>
  2. #include <stdio.h>
  3. #include <string.h>
  4.  
  5. char *pwd = "9i2ht16";
  6. void printPassword() {
  7. printf("Password is: %s", pwd);
  8. }
  9. int decrpytName(char *theName) {
  10. char name[20];
  11. strcpy(name, theName);
  12. if (name[0] == 'V') {
  13. printPassword();
  14. return 1;
  15. } else {
  16. printf("Authentication Failed");
  17. return 0;
  18. }
  19. }
  20. int main(int argc, char *argv) {
  21. if (argc < 2) {
  22. printf("Usage: Enter name");
  23. exit(0);
  24. }
  25. int authCode = copyTheString(argv[1]);
  26. return 0;
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement