CS 1500, Fall 2010
Solo Program 3



OBJECTIVE:

This assignment is designed to give you practice using doubles in mathematical functions and writing programs with user-defined functions.


THE ASSIGNMENT:

Your assignment is to write a program that computes the average and standard deviation for four values input by the user.

To do this you will need to write three functions:

1.  //explains program to user and directs them to enter appropriate values.
      void printDirections();

2.  //returns the arithmetic mean of the four arguments.
      double  average(double s1, double s2, double s3, double s4);

       The average is the sum of the values divided by the number of values (four in this case).
       It is also called the arithmetic mean.


3.  //returns the standard deviation of the four arguments.
     double stdDev(double s1, double s2, double s3, double s4);

       To compute the standard deviation:
Here is shell program to get you started.


INPUT AND OUTPUT:

The program must prompt for four double values.

The program must compute the average and standard deviation of the values and report them to the user.

After the results are reported the program must ask the user if they would like to continue and either repeat or exit, depending on the user's choice.

Have a look at the sample script to see how it should look when you run the program.

TESTING:
Your script should include at least 10 test cases, including the following:

WHAT TO TURN IN:

Here is the list of things you have to turn in:

DUE DATES:

For the due dates, see the class schedule.