The world’s Largest Sharp Brain Virtual Experts Marketplace Just a click Away
Levels Tought:
Elementary,Middle School,High School,College,University,PHD
| Teaching Since: | Apr 2017 |
| Last Sign in: | 103 Weeks Ago, 3 Days Ago |
| Questions Answered: | 4870 |
| Tutorials Posted: | 4863 |
MBA IT, Mater in Science and Technology
Devry
Jul-1996 - Jul-2000
Professor
Devry University
Mar-2010 - Oct-2016
A java application called Numbers, that reads two integers from the keyboard (a minimum and a maximum range).
Based on the minimum and the maximum integers, the application should:
List all of the numbers in the range
List the even numbers in the range (using a conditional operator)
List the odd numbers in the range (using a conditional operator)
List the total numbers in the range
List the sum of all the numbers in the range
Calculate the average of the numbers in the range
Using at least one for loop, either a while loop or a do while loop and a conditional operator for calculating even and odd numbers.
So the output should look like this;
Enter the minimum value of the range of numbers: 3
Enter the maximum value of the range of numbers: 6
The numbers in the range are                  : 3 4 5 6
The even numbers in the range are             : 4 6
The odd numbers in the range are              : 3 5
The total numbers in the range are            : 4
The sum of the integers is                    : 18
The average number in the range is            : 4
-----------