Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- bool playAgain(void){
- char cRetry[2];
- cRetry[0] = '\0';
- while((tolower(cRetry[0]) != 'y') && (tolower(cRetry[0]) != 'n')){
- printf("Would you like to try again? [y/n]");
- fgets(cRetry, 2, stdin);
- }
- return(tolower(cRetry[0]) == 'y');
- }
Advertisement
Add Comment
Please, Sign In to add comment