Hangman game written in C programming language
A simple terminal-based Hangman game written in C.
The program randomly selects a fruit name from a predefined list, and the player has 7 attempts to guess the correct word.
- Random word selection (fruits)
- Underscore-based hidden word display
- Tracks correct and incorrect guesses
- Game ends when:
- All letters are correctly guessed, or
- The player reaches 7 wrong attempts
- C compiler (e.g., GCC)
- Terminal or Command Prompt
- The word is shown as underscores.
- Enter one letter each turn.
- Each wrong letter increases the mistake count.
- You win if you guess the entire word before reaching 7 mistakes.
git clone https://github.com/<your-username>/hangman.git
cd hangman
gcc hangmanGame.c -o hangman
./hangman # Windows users: hangman.exe