Hangman



This is a popular game which most of us used to play while sitting on the back benches in our classrooms. Well, I have tried to make the same game in C++. Hope you like it.

The game is very simple. The computer selects a word from the file "HANGMAN.DAT" and shows stars instead of the word on the screen. You have to guess the word in 7 chances. If the man is hanged then the game is over.

More words can be added to the database by using the "Storewrd.cpp" program. The size of each record is 20 bytes. Deleting/Modifying can be easily done by the following way:

  • Open the file in Edit as - Edit /20 hangman.dat
  • Delete/modify the word which you want to delete/modify.
  • Save and exit

Important

I used the Turbo C++ compiler to make this program.

The following files must be in the same directory / folder:

  • HANGMAN.CPP / HANGMAN.EXE
  • HANGMAN.DAT
  • BOLD.CHR
  • TRIP.CHR
  • TSCR.CHR
  • EGAVGA.BGI

 

Cheat Code

Press * during gameplay and type "GONZOOPERA" in caps. The word will be displayed. For the next game you again have to enter the cheat code.

Pressing Esc anytime during the game exits the game.

How to Contact Me

My email address is jaydeepbodwadkar@yahoo.co.in

Any suggestions are welcome.

Download