![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| help me in sending parameters from sqlplus script to unix shell script | Hara | Shell Programming and Scripting | 2 | 01-29-2008 03:31 PM |
| Speaking Hangman is fun for the whole family | iBot | UNIX and Linux RSS News | 0 | 01-04-2008 05:20 PM |
| Script for Hangman Game | immyakram | Shell Programming and Scripting | 0 | 11-20-2007 06:46 PM |
| Shell Script: want to insert values in database when update script runs | ring | Shell Programming and Scripting | 1 | 10-25-2007 03:06 AM |
| Hangman written in Bash. Suggestions please... | rorey_breaker | Shell Programming and Scripting | 1 | 09-26-2007 07:57 PM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
Hangman Script
Hello everyone, im just having some problem forming a script for a hangman script. The question states:
The object this excercise is for u to write a script that emulate the classic game hangman. The object of this game is for a user to try and guess a word which has been generated by the program. The user will generally have a certain amount of lives and is then requested to try and guess a letter in the owrd. on successful guesses the letter is shown within the word in its relevant position. An unsuccessful guess leads to a loss of a life. A reord of guessed letters must be kept and displayed. Specification 1) The program will allow for a 1 player game. The word to be guessed is randomly generated from a list of stored words. 2)The guessed letters must be visible to the player. 3)The current lives must be visible 4)The number of guesses must be visisble 5)When the number of lives has run out or the word is guessed a mesage should be displayed to the user stating how they ahve done. Example.. Sorry the word was "THE_SECRET_WORD" OR Well done the word was "THE_SECRET_WORD" you guessed it in 15 attempts with the loss of 2 lives 6) you must prompt te er to ask if they wish to play again. 7)your application should prevent the user entering characters other than letters. the user should only be able to enter one letter at a time. If anyone could post how i could overcome this problem it would be great, if some one could have a crack at this and maybe post syntax i would be really please. Many Thanks in advance. |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|