Question: .Create a console-based lottery game application named Lottery. Generate three random numbers, each between 1 and 4. Allow the user to guess three numbers. Compare
.Create a console-based lottery game application named Lottery. Generate three random numbers, each between 1 and 4. Allow the user to guess three numbers. Compare each of the users guesses to the three random numbers and display a message that includes the users guess, the randomly determined three-digit number, and the amount of money the user has won as follows: Matching Numbers Award ($) Any one matching 10 Two matching 100 Three matching, not in order 1000 Three matching in exact order 10,000 No matches 0 Make certain that your application accommodates repeating digits. For example, if a user guesses 1, 2, and 3, and the randomly generated digits are 1, 1, and 1, do not give the user credit for three correct guessesjust one. b.Create a GUI application named LotteryGUI that lets the user play the Lottery game described in Exercise 9a.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
