CS21 Week6 In-Class Exercises

  1. We are going to continue with last week's in-class assignment. If you have not already done so, create a week5 subdirectory and copy over my starting point files:
    % cd  
    % cd cs21
    % mkdir week5
    % cd week5
    % pwd 
    % cp ~newhall/public/cs21/week5/* .   
    

    We will continue with the TODO parts of this assignment.

    In addition we will add the following part if we have time:

            // TODO: write a method TopThree, that takes the grades array
            //       and its effective size, and returns an array with three
            //       buckets containing the three largest grades in the grades
            //       array.  If the grades array has fewer than 3 grades, then
            //       your returned array should have -1s in any buckets that 
            //       are invalid.  The method should also return null on an
            //       error.
            //
            //       Call this method with your grades array and print out
            //       the resulting top 3 grades.