{"id":104838,"date":"2022-11-13T01:16:15","date_gmt":"2022-11-13T01:16:15","guid":{"rendered":"https:\/\/assignmenttutors.net\/blog\/cs101-final-project-hangman\/"},"modified":"2022-11-13T01:16:15","modified_gmt":"2022-11-13T01:16:15","slug":"cs101-final-project-hangman","status":"publish","type":"post","link":"https:\/\/assignmenttutors.net\/blog\/cs101-final-project-hangman\/","title":{"rendered":"Cs101 &#8211; final project: hangman"},"content":{"rendered":"<div>\n<p><strong><span>General Instructions:<\/span><\/strong><\/p>\n<p><span>\u00a0<\/span><\/p>\n<p><span>Create a simple hangman game.<\/span><\/p>\n<p><span>\u00a0<\/span><\/p>\n<p><span>Hangman is played as follows:<\/span><\/p>\n<p><span>\u00a0<\/span><\/p>\n<ol>\n<li><span>One player chooses a secret word, then writes out a number of dashes equal to the word length. <\/span><\/li>\n<\/ol>\n<p><span>\u00a0<\/span><\/p>\n<ol>\n<li><span>The other players begin guessing letters. If a player guesses a letter that&#8217;s in the word, the first player reveals all instances of that letter in the word. Otherwise, the guess is incorrect. <\/span><\/li>\n<\/ol>\n<p><span>\u00a0<\/span><\/p>\n<ol>\n<li><span>The game ends either when all the letters in the word have been revealed or when the guessers have run out of guesses. <\/span><\/li>\n<\/ol>\n<p><span>\u00a0<\/span><\/p>\n<p><strong><span>Specific Instructions:<\/span><\/strong><\/p>\n<p><span>\u00a0<\/span><\/p>\n<p><span>The entire logic for this program should be written in a <strong>User-defined<\/strong> class. You should run your program until the user decides to end the game.<\/span><\/p>\n<p><span>\u00a0<\/span><\/p>\n<p><span>Your program should do the following:<\/span><\/p>\n<p><span>\u00a0<\/span><\/p>\n<ol>\n<li><span>Prompt the user for a word length, re-prompting as necessary until the user enters a number such that there&#8217;s at least one word that&#8217;s exactly that long. That is, if the user wants to play with words of length -42 or 137, since no English words are that long, you should re-prompt her. <\/span><\/li>\n<\/ol>\n<p><span>\u00a0<\/span><\/p>\n<ol>\n<li><span>Prompt the user for a number of guesses, which must be at an integer greater than zero. <\/span><\/li>\n<\/ol>\n<p><span>\u00a0<\/span><\/p>\n<ol>\n<li><span>Print out how many guesses the user has remaining, along with any letters the player has guessed and the current blanked-out version of the word. <\/span><\/li>\n<\/ol>\n<ol>\n<li><span>If the player has run out of guesses, display the secret word. <\/span><\/li>\n<\/ol>\n<ol>\n<li><span>If the player correctly guesses the word, display congratulations. <\/span><\/li>\n<\/ol>\n<p><span>\u00a0<\/span><\/p>\n<p><span>\u00a0<\/span><\/p>\n<p><strong><span>Expectations:<\/span><\/strong><\/p>\n<p><span>\u00a0<\/span><\/p>\n<ol>\n<li><span>Your work should be properly documented. <\/span><\/li>\n<\/ol>\n<ol>\n<li><span>A user-defined class is used to implement your solution <\/span><\/li>\n<\/ol>\n<p><span>\u00a0<\/span><\/p>\n<p><strong><span>Please personalize your program.<\/span><\/strong><\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>General Instructions: \u00a0 Create a simple hangman game. \u00a0 Hangman is played as follows: \u00a0 One player chooses a secret word, then writes out a number of dashes equal to the word length. \u00a0 The other players begin guessing letters. If a player guesses a letter that&#8217;s in the word, the first player reveals all [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[16],"tags":[],"class_list":["post-104838","post","type-post","status-publish","format-standard","hentry","category-education"],"_links":{"self":[{"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/posts\/104838","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/comments?post=104838"}],"version-history":[{"count":0,"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/posts\/104838\/revisions"}],"wp:attachment":[{"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/media?parent=104838"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/categories?post=104838"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/tags?post=104838"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}