Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

USING JAVA Create a simple application game that generates 4 random numbers each between 1 and 2 5 ( no duplicate numbers ) . Allow

USING JAVA Create a simple application game that generates 4 random numbers each between 1 and 25(no duplicate numbers). Allow the user to guess 4 numbers. If the user enters a duplicate number, display a message saying duplicate number and have them enter another number. Make sure they enter 4 different numbers. Compare the numbers to the computer generated random numbers (only 1 match per number, no duplicate number matches) and display a message if the user guessed the following:
1) None of your numbers were matched
2) One number matched
3) Two numbers matched
4) Three numbers matched
5) If Four numbers are matched display a winning message.
Also, display the random generated number and the users 4 numbers entered separated by spaces.
Make the random generated number variable name be randomLuck1
Example: ( But feel free to make it look different, just make sure you have this information displayed)
Two numbers matched
Computer generated number: 310520
Your numbers: 110524

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Processing

Authors: David Kroenke

11th Edition

0132302675, 9780132302678

More Books

Students also viewed these Databases questions

Question

In an Excel Pivot Table, how is a Fact/Measure Column repeated?

Answered: 1 week ago