Sign in to follow this  
Fluffy21

HangMan

Recommended Posts

hello my name is john i am a teacher that teaches c++ and are school has microsoft c++ books but i didn't see a hangman program in their i was wondering if you could make me a program that has voids and for loops. it doesn't have to be high class i just need a simple program to guide my students threw thanks John

Share this post


Link to post
Share on other sites
I think the point is, in order to teach something, you have to understand it yourself. So taking source code you didn't write (and maybe don't understand) and trying to teach others what it does and why it does it, is probably not the best of ideas.

Even without that in mind, I doubt anyone will simply write you a hangman game, but we would be more than happy to assist you to write your own [smile]

All the best,
ViLiO

Share this post


Link to post
Share on other sites
Quote:
Original post by Nytegard
Google

I thought these types of questions were against the rules of Gamedev, or at least don't belong in this forum.


No, they're about homework AFAIK, but I don't think anyone thought about a teacher asking for that kind of "help" in here :P

Share this post


Link to post
Share on other sites
That's not a too bad start (although there is at least two fatal mistakes).

So, there you have a couple of lines, just keep adding the lines, and if you get any problems after you're done, we'll gladly help you out.

Share this post


Link to post
Share on other sites
If you know how the logic in a Hangman game should work (either in another language or in pseudo-code) then it's just syntax wrangling from here on out.

If you don't mind me asking, what do you usually teach?

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
My guess is that the OP is actually a student in the class and has been assigned to write the hangman prog. He is posing as the instructor to try and circumvent the gamedev rules.

Share this post


Link to post
Share on other sites
Quote:
Original post by Anonymous Poster
My guess is that the OP is actually a student in the class and has been assigned to write the hangman prog. He is posing as the instructor to try and circumvent the gamedev rules.

Welcome to Gamedev.net, Sherlock! [grin]

Share this post


Link to post
Share on other sites
I could believe he's a sub; we had a sub for the last few weeks of high school chemistry (right before the final exam) that came in from English. We ended up teaching it to her, which was sub-optimal. Subs aren't prepared for their gigs very well in public school.

Share this post


Link to post
Share on other sites
Quote:
Original post by Fluffy21
yea but the regular teach had them do worksheets y??


Because your grammar is atrocious, but I digress.

As far as making you HangMan game, before you can figure out what code you need, you should think about the basic logic of the game HangMan.

Will you randomly pick the word from a list or have a user input it first?
How will you represent the person being hung if the user guesses wrong (ASCII art would probably be easiest)?
How will you handle user input to begin with?
Et cetera.

Share this post


Link to post
Share on other sites
so it would start out with something like this
#include<iostream.h>
//-----------------------
void word(int &Wor)
{
cout<<"Enter a Word to be guessed"<<endl;
cin>>Wor;
system('cls')
}
//--------------------------------
void guess(int&Let)
{
cout<<"Guess a Letter"<<endl;
cin>>Let;
//-------------------------------------------
int main()
{
int Wor=0;
int Let=0;

Word(Wor);
Guess(Let);
return(0);
}
from their what do i do

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this