import java.util.Scanner; /** * Solution to HW 1, Programming Project 6.3, page 204 * * @author Melvin Fitting * @version Jan 25, 2008 * * */ public class HW1 { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); final int QUANTITY = 10; int[] numberList = new int[QUANTITY]; /** * Get the numbers from the user */ for(int n = 0; n < QUANTITY; n++){ System.out.println("Enter an integer"); numberList[n] = scanner.nextInt(); } /** * Display the numbers in reverse order */ for(int n = QUANTITY-1; n >= 0; n--) System.out.println(numberList[n]); } }