forked from menault/TD3_DEV51_Qualite_Algo
		
	Actualiser pendu.c
This commit is contained in:
		
							
								
								
									
										6
									
								
								pendu.c
									
									
									
									
									
								
							
							
						
						
									
										6
									
								
								pendu.c
									
									
									
									
									
								
							@@ -109,11 +109,11 @@ int play_game(const char *word, int word_length) {
 | 
			
		||||
        char guess;
 | 
			
		||||
 | 
			
		||||
        alarm(30);
 | 
			
		||||
        printf("Entrez une lettre (ou 'q' pour quitter) : ");
 | 
			
		||||
        printf("Entrez une lettre (ou '1' pour quitter) : ");
 | 
			
		||||
        scanf(" %c", &guess);
 | 
			
		||||
        alarm(0);
 | 
			
		||||
 | 
			
		||||
        if (guess == 'q') {
 | 
			
		||||
        if (guess == '1') {
 | 
			
		||||
            printf("Vous avez quitté le jeu. À bientôt !\n");
 | 
			
		||||
            return 0;
 | 
			
		||||
        }
 | 
			
		||||
@@ -167,7 +167,7 @@ int main() {
 | 
			
		||||
        char word[256] = "";
 | 
			
		||||
        choose_random_words(filtered_words, num_filtered_words, word, max_word_length);
 | 
			
		||||
        int word_length = strlen(word);
 | 
			
		||||
        printf("%s",word)
 | 
			
		||||
        printf("%s",word);
 | 
			
		||||
        int score = play_game(word, word_length);
 | 
			
		||||
 | 
			
		||||
        char play_again;
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user