Created
October 18, 2011 19:37
-
-
Save b-adams/1296466 to your computer and use it in GitHub Desktop.
Nesting versions
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This is the main function. | |
// program MAIN; | |
#include <stdio.h> | |
int main(void) | |
{ | |
if(gamepoint<10) | |
{ | |
printf("Strike!"); | |
} | |
else | |
{ | |
printf("All right! Keep it up!"); | |
} | |
if (setpoint<14) | |
{ | |
printf("Strike!"); | |
} | |
else | |
{ | |
printf("Nice! Can you really get it?"); | |
} | |
if (12+gamePoint+setPoint<18) | |
{ | |
printf("You...didn't get it, sorry. Better luck next time."); | |
} | |
else | |
{ | |
printf("You did it! You got the gold trophy! Nice job!"); | |
} | |
printf("Thanks for playing! Please take a small money prize for"); | |
printf("taking part in it. Remember, victory is golden!"); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment