Sample 03


This menu-driven, console program is a variation of the previous sample program. The application source file contains the definition of an instantiable SalesRep class that encapsulates the data and processing of a sales representative. The App class constructs and uses an array of SalesRep objects to maintain data about a group of sales representatives.

To run the program, you must be familiar with how to run Java sample code using a "test" project. If you already have a test project, copy and paste the source statements of this Sample03.txt file into the source file of your test project. Then, re-build the test project and launch its App class.

NOTE: The main method expects to receive an even number of parameters representing the name and commission rate of each sales representative. For example:

Ken 7.25 Karen 7.0 Mary 6.75 David 6.5

as application parameters. Consult the documentation of your Java development environment for information on how to pass parameters to the application at project at run time.