{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Project_08 - COMP 1210 Project 8 Enhanced Number Guessing...

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

View Full Document Right Arrow Icon
COMP 1210 Project 8: Enhanced Number Guessing Page 1 of 4 Due : Monday, March 19, 2012 by 11:59 PM Deliverables The following project files must be submitted to the “graded” assignment in Web-CAT by the due date and time specified above (see the Lab Guidelines for information on submitting project files). You should plan to start on the project not later than Wednesday in lab, and you should make sure that your files are successfully submitted to the “ungraded” assignment in Web-CAT during lab on Wednesday. Projects sent via e-mail past the deadline at 11:59 PM will not be accepted without a university- approved excuse. Files to submit to Web-CAT: Number.java Game.java EnhancedNumberGuessingApp.java Specifications Overview: Design an application that plays a guessing game with numbers. The program should allow the user to enter the number of digits (1 to 9) that the computer’s number will have, generate the number so that the digits consists of different random numbers between 0 and 9 (inclusive) in a certain combination, and then repeatedly prompt the user to guess the combination of these digits. The user’s guess input must be a integer with the same number of digits as the computer’s number (the digits are not separated by spaces ). For each guess, report to the user how many of the guessed digits were totally right (i.e., both the number and position were correct) and how many of the guessed digits were correct but in the wrong position. Continue accepting guesses until the user guesses correctly or until the user enters “key” or “end” to quit and see the answer. Count the number of guesses and report that value as part of the output that prefaces the guess as shown in the example below.
Background image of page 1

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

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

{[ snackBarMessage ]}