Question: A Find abe Replace Date and Insert time object Select all ert Editing g or displayed improperly . Write a program that should have the

 A Find abe Replace Date and Insert time object Select all

A Find abe Replace Date and Insert time object Select all ert Editing g or displayed improperly . Write a program that should have the following name fields and methods to test your ESP (extrasensory perception) ESPGame -computer: String user: String +runComputerO: void + setUserChoice0:void +isValidO:boolean +whoWinsO: String The program should randomly select the name of a color from the following list of words: runComputerO method-> This method generates a random number. For example, if the number is 0, the selected word is Red, if the number is 1, the selected word is Green; and so forth. It assigns the selected word to the field computer setUserChoice0 method->This method asks the user to enter a color that the computer has selected and assigns the user choice to the field 'user'. If the color is not the one that is used for ESP game, the user needs to be prompted continuously until the valid choice is entered. isValidO method-> It accepts the user choice as its parameter and returns true if the choice is 'red', 'green', 'blue', 'orange' or 'yellow'. Otherwise returns false whoWinsO method-> It accepts the user choice and the computer selection as its parameters and returns the winner ('user' or 'computer'). Note: Ignore case sensitivity Write an application program named 'LetsPlay'. The program should run the game 10 times and then display the grand winner of the game. Be sure to modularize the program into methods that perform each major task. Grading criteria include documentation descriptive variable names, and adherence to the codiang convention noted on pages 1 & 2

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!