473,386 Members | 1,803 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

NO programming experience at all in need of help - Hangman game

I have never done any programming in my life but I have decided to go into engineering and in doing so we have to take this intro to programming course and I am pretty clueless. I am starting to get the hang of how python works but to put my thoughts into the program to make it run is the confusing part for me.

The task is to implement a Hangman game and the Program Specifications are:

1) Output a brief description of the game of hangman and how to play
2) Ask the user to enter the word or phrase that will be guessed (have a friend enter the
phrase for you if you want to be surprised)
3) Output the appropriate number of dashes and spaces to represent the phrase (make sure
it’s clear how many letters are in each word and how many words there are)
4) Continuously read guesses of a letter from the user and fill in the corresponding blanks if
the letter is in the word, otherwise report that the user has made an incorrect guess.
5) Each turn you will display the phrase as dashes but with any already guessed letters filled
in, as well as which letters have been incorrectly guessed so far and how many guesses
the user has remaining.
6) Your program should allow the user to make a total of k=6 guesses.
7) You MUST use at least 3 string methods or operators in a useful manner (several
examples that I used are given in the notes below). If you wish to use lists in your project
that is fine, as long as you meet this requirement.

I am willing to learn and put as much effort as needed I really want to understand. Any help would greatly be appreciated.
Sep 18 '08 #1
5 4173
YarrOfDoom
1,247 Expert 1GB
Could you post what you already have?(code so far, pseudocode, logics scheme,...) It would be easier to help you out with it then.

edit: I see you're new here, so welcome to Bytes, don't forget to use [code]-tags and please read the Posting Guidelines . Enjoy the site!
Sep 19 '08 #2
oler1s
671 Expert 512MB
If you look at your assignment, it’s been broken down into tasks, and you should do them in order. The first task, for example, asks you to output something. I presume you had some class lectures, and you were actually shown how to output something in Python. If you’re having trouble even with that much, you may want to go to office hours, a session with the teaching assistant or the like. At a certain point, what you need is a full out tutoring session, not a single question answered.
Sep 20 '08 #3
Wow, that looks interesting, i want to see the final work.
i sniffed around and didn't find any articles related to limiting the text input or any
other shortcut i can find on the internet, because you obviously don't want to learn
it as a long lecture from a teacher and you want to get the straight and in-to-the-point version of it, the best i can do is to tell you to go get a book about it.
you can see this post http://bytes.com/forum/thread838830.html
for some book suggestions.
Hope you will make it :D
Sep 26 '08 #4
aberry
10
I have seen similar problem (or say same) problem at MIT OCW course assignment.

here is the link of course and check assignment # 3 and 4.

http://ocw.mit.edu/OcwWeb/Electrical...ents/index.htm

It contains helper functions and approach to solve this puzzle. I was able to do 1st part with success (asg # 3)...

hope this will help you ...
Sep 26 '08 #5
bvdet
2,851 Expert Mod 2GB
There are a few other threads on hangman. Here's one that has some code in it:
Hangman
Sep 26 '08 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: DaMan | last post by:
Can anyone recommend a good book that teaches how to program basic games in C++? I have some C and C++ experience, but not too much with graphics. The kind of game I want to write is a simple...
1
by: rainbowii7 | last post by:
Calling all programmers for helllllllllllllllppppp!!! i am currently doing a uni degree and our lecturers have set us the task of making a game in JavaScript. i chose to do a hangman game and...
5
by: tigrfire | last post by:
So I'm trying to write a hangman game and the output is coming out a little strange. Here's my code thus far: #include <stdio.h> #include <string.h> #include <stdlib.h> #include <time.h> ...
57
by: Need help54321 | last post by:
Ok hes the thing u no public class thats how i gotta make it in JCreator and i dont even no where to start if anyone could give me some pointer or make the code and i use bits and piece That would...
4
by: princessfrost | last post by:
Hi! I was wondering if someone could please help me with a hangman program that I have to do. I have some ideas, but really don't know what to do or where to start. My program needs to be:...
47
by: araujo2nd | last post by:
Originally Posted by araujo2nd my name is andre, im from south africa, i was wondering if any1 could help me with a hangman application, im now in grade 11 and have a huge portfolio piece to do by...
3
by: kaka_hunter | last post by:
#include <iostream> #include <fstream> using namespace std; const int max_tries=7; int earnings=0; int wordnum; void getword () { ifstream fin;
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.