Thats why I was getting that horrible error #-o
I was pass the value of highest vote as the index value for enteredNames but enteredNames's index only goes up to 4.
Now the program is complete....
Type: Posts; User: Java'88
Thats why I was getting that horrible error #-o
I was pass the value of highest vote as the index value for enteredNames but enteredNames's index only goes up to 4.
Now the program is complete....
Thats what I was think too, when I said "I know what is needed to find the winner of the election."
I can find the highestvote but finding or passing the index of the max votes is what I need...
So far everything is good. Just finding the winner of the election is the only thing left before the program is complete. I know what is needed to find the winner of the election, but I just don't...
Snice you have remove those methods what should I do with those two line of code? If I remove them I get lots of errors and if I keep them, Eclipse ask back for the method that you removed.
...
I'm not really sure where I can substitute your code as I getting lots of error when I do substitute in this part of the program:
..........
public String[] readNames()
{
...
Okay, but what about the candidate's name and vote. As you can see I have to first ask for the names then again for the votes, which doesn't fit the description of program or the sample of how it...
Description of what the program should do:
The program should allow the user to enter the last names of five candidates in a local election and
the votes received by each candidate.
The...