#include #include #include // We don't need this // It's called strcmp, and it's in the string library! int compare(char* a, char* b){ for(int i = 0;a[i] != 0 && b[i] != 0; i++){ if(a[i] != b[i]) return 0; } return 1; } int main(int argc, char ** argv){ char *answer = getenv("MAGIC_WORD"); for(int i = 1; i < argc; i++){ if(!strcmp(answer, argv[i])){ printf("Got it!\n"); return 0; } } printf("Sorry, try again\n"); return 0; }