Home › Forums › Decaffeinated Coffee › Java Problem › Reply To: Java Problem
January 26, 2012 3:37 pm at 3:37 pm
#846533
ItcheSrulik
Member
You want your loop to store each player’s average in an array. Then you want to call max to find the highest average.
Here are a couple comments on your program.
1- Where are your comments? Right now you aren’t dealing with production code so you don’t see how important documentation is yet, but it’s a good habit to get into and it makes it easier for people to understand your code when you need help.
2- Why do you create a new scanner on every method call?
3- Why are you dividing by the number of players times the number of games?
BTW, which school teaches Java as an intro language?