|
|
|
Recitation Topic: AscendingOut
|
Date: 10/28/2005
- Write a static method getOneIntFromUser which takes as input a reference
to a Scanner object and returns an integer. This method should repeatedly query
the user to input an integer, and return as soon as the user inputs a numerical
string that can be interpretted as an integer. The method should return that
integer the user input.
- Write a static method indexOfMin that takes as input an array of integers
and outputs the (integer) index of the smallest of those integers.
- Write a program that reads in integers from the user and then outputs
those integers to the screen in ascending order. Hint: Consider an array to hold the users integers, and a second
array of booleans that holds 'true' for each integer you've already output to the screen.
|
|