/**
 *  File: AddEmUp.java
 *
 *  Requests a sequence (<100) of positive numbers from the user.
 *  Keyboard input. Input is terminated by any value <= 0.
 *  The values are stored in an array.
 *  The array is then sorted, displayed, and the average is displayed.
 *  Data.java contains the data that we'll work with.
 *
 *  Author: Bary W Pollack
 *  Date:   Jan. 7, 2007
**/

public class AddEmUp {

	// The main method for Java - all the real "work" is orchestrated from here
	public static void main(String[] args) {
		System.out.println("\n*** AddEmUp ***\n");
		System.out.println("Enter a sequence of numbers; end with a value <= 0");
		System.out.println("You may place several values on a line; separate with whitespace\n");

		// Create Data for this problem
		Data data = new Data();

		// Do the actual "work"
		data.input();
		data.display("Intial data:");
		data.sort();
		data.calculate();
		data.display("Sorted data:");

		System.out.println("\nThat's all, folks!\n");
	} // end main()

} // end AddEmUp class
