Question: In a class named SmallAndLarge, write a program that asks the user to enter numbers, then prints the smallest and largest of all the numbers

In a class named SmallAndLarge, write a program that asks the user to enter numbers, then prints the smallest and largest of all the numbers supplied by the user. You may assume that the user enters a valid number greater than 0 for the number of numbers to read. Here is an example:

How many numbers do you want to enter? 4 Number 1: 6 Number 2: 18 Number 3: 3 Number 4: 7 Smallest = 3 Largest = 18 

This is in Java.

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!