Thread: Help on hangman program

  1. #1
    Registered User
    Join Date
    Jan 2007

    Help on hangman program

    How can i implement my Hangman Program using at least one class function in the program? Please teach me...

  2. #2
    Registered User
    Join Date
    Jan 2005
    If you want to add a class to the program, you could start by putting everything into the class. All the variables you are used in multiple places could be member variables. The functions could be member functions and use the member variables instead of having separate arguments. The code in main could be in a member function of the class and you could just create an instance of the class in the empty main() and call it's main function to run the simulation.

    If you can get that working, you could try to find other things that do separate jobs that you could separate out into their own classes.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Help with Hangman program
    By Trank07 in forum C Programming
    Replies: 1
    Last Post: 11-24-2007, 10:00 PM
  2. Using variables in system()
    By Afro in forum C Programming
    Replies: 8
    Last Post: 07-03-2007, 12:27 PM
  3. BOOKKEEPING PROGRAM, need help!
    By yabud in forum C Programming
    Replies: 3
    Last Post: 11-16-2006, 11:17 PM
  4. My program, anyhelp
    By @licomb in forum C Programming
    Replies: 14
    Last Post: 08-14-2001, 10:04 PM