Guest User

Student Class

a guest
Oct 18th, 2012
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 1.31 KB | None | 0 0
  1. // ****************************************************************
  2. // Student.java
  3. //
  4. // Define a student class that stores name, score on test 1, and
  5. // score on test 2. Methods prompt for and read in grades,
  6. // compute the average, and return a string containing student’s info.
  7. // ****************************************************************
  8.  
  9. public class Student {
  10.  
  11.     // declare instance data
  12.     // -----------------------------------------------
  13.     // constructor
  14.     // -----------------------------------------------
  15.     // create a constructor that takes in the student name as a parameter
  16.     // add body of constructor
  17.  
  18.     // -----------------------------------------------
  19.     // inputGrades: pass in grades 1 and 2 into this method.
  20.  
  21.     // -----------------------------------------------
  22.     // create method for the input grades method
  23.  
  24.     // add body of inputGrades
  25.  
  26.     // -----------------------------------------------
  27.     // getAverage: compute and return the student's test average
  28.     // -----------------------------------------------
  29.     // add header for getAverage
  30.     {
  31.         // add body of getAverage
  32.     }
  33.     // -----------------------------------------------
  34.     // getName: print the student's name
  35.     // -----------------------------------------------
  36.     // add header for printName
  37.     {
  38.         // add body of printName
  39.     }
  40. }
Advertisement
Add Comment
Please, Sign In to add comment