1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57
| int __cdecl __noreturn main(int argc, const char **argv, const char **envp) { char v3[29]; int v4; int v5; int i; char v7[12];
__main(); v4 = 0; strcpy(v3, "*11110100001010000101111#"); while ( 1 ) { puts("you can choose one action to execute"); puts("1 up"); puts("2 down"); puts("3 left"); printf("4 right\n:"); scanf("%d", &v5); if ( v5 == 2 ) { ++*(_DWORD *)&v3[25]; } else if ( v5 > 2 ) { if ( v5 == 3 ) { --v4; } else { if ( v5 != 4 ) LABEL_13: exit(1); ++v4; } } else { if ( v5 != 1 ) goto LABEL_13; --*(_DWORD *)&v3[25]; } for ( i = 0; i <= 1; ++i ) { if ( *(int *)&v3[4 * i + 25] < 0 || *(int *)&v3[4 * i + 25] > 4 ) exit(1); } if ( v7[5 * *(_DWORD *)&v3[25] - 41 + v4] == 49 ) exit(1); if ( v7[5 * *(_DWORD *)&v3[25] - 41 + v4] == 35 ) { puts("\nok, the order you enter is the flag!"); exit(0); } } }
|