Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int main () {
- int count = 0;
- char answer = ' '; // anything but 'q'
- // first run, so start the kitchen
- system("python3 superr");
- while (answer != 'q') {
- printf("\n\n\"Q\" to Quit, or \"R\" to Restart, then press ENTER\n");
- scanf (" %c", &answer);
- answer = tolower(answer);
- if (answer != 'r' && answer != 'q') {
- printf("Which part about Q or R did you not understand, you twat?\n");
- // continue; // back to beginning of loop
- }
- else if (answer == 'r') {
- count++;
- if ((count % 10) == 1 && count != 11)
- printf("Restarting the kitchen for the %dst time\n", count);
- else if ((count % 10) == 2 && count != 12)
- printf("Restarting the kitchen for the %dnd time\n", count);
- else if ((count % 10) == 3 && count != 13)
- printf("Restarting the kitchen for the %drd time\n", count);
- else
- printf("Restarting the kitchen for the %dth time\n", count);
- system("python3 superr"); // restart kitchen
- // continue; // back to beginning of loop
- }
- else {
- printf("Fine you want to quit, so be it -_-\n");
- // break; // 'q' is selected break out of loop
- }
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment