cs31s11extra

cs31s11extra - CS31: Introduction to Computer Science I...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
CS31: Introduction to Computer Science I Spring 2011 Copyright Brian Choi 2011. All Rights Reserved. 1 Bonus Problem TA: Brian Choi (schoi@cs.ucla.edu) Section Webpage: http://www.cs.ucla.edu/~schoi/cs31 In this problem, we will create a word puzzle manager for the game of Wheel of Fortune, by constructing a WheelOfFortune class. In the case you have never watched this show (which I think is rare), think of it as a hangman game, where you have a word puzzle and keep guessing letters that appear in the puzzle until you figure out the puzzle. Here, a (word) puzzle is a phrase or a sentence in English that consists only of alphabets and spaces. For example, “ Los Angeles Lakers ” is a valid puzzle, while “ Philadelphia 76ers ” is not. A puzzle can be arbitrarily long. If the puzzle is “ Los Angeles Lakers ”, before solving the problem, it appears as “ ### ####### ###### ” (the unsolved portion of the puzzle appears as # s). When a contestant’s guess is S , it then alerts the user that there are three S ’s in the puzzle, and replaces the corresponding # s in the puzzle with S , which thus becomes “ ##S ######S #####S ”. At any time, the contestant can try to solve the puzzle.
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 07/06/2011 for the course CS 31 taught by Professor Melkanoff during the Spring '00 term at UCLA.

Page1 / 3

cs31s11extra - CS31: Introduction to Computer Science I...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online