Question: In Java, Write a program that generates a random integer from 1 - 15, inclusive. Then print the number and report that the number is

In Java,

Write a program that generates a random integer from 1 - 15, inclusive.

Then print the number and report that the number is over 5, under 5, or equal to 5.

example output:

The random number was : 12, which is greater than 5

The random number was : 2, which is less than 5

The random number was : 5, which is equal to 5

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!