View Single Post
  #3 (permalink)  
Old 09-14-2008, 01:40 AM
Fubarable's Avatar
Fubarable Fubarable is online now
Senior Member
 
Join Date: Jun 2008
Posts: 1,271
Fubarable is on a distinguished road
There's a lot of redundancy in that code including 3 methods that are exactly alike, and should be compressed into one method.

1) Look at using the Random class to generate your random numbers.
2) Again there is a tremendous amount of redundancy here including 3 methods that are exactly alike and could all be made into one method, and a long 20 line if statement that can be condensed into one line of code using the String.valueOf(...) method.
3) How are you storing the grade for each student? why not an int? why not then add the ints?
4) Where's your main method? Student class?
Reply With Quote