Explore BrainMass

C++ program to calculate and display election results

I need help with the following program. I have an attachment with the code written. I just need the code added to where the info can be read in from a file.

Write a program that allows the user to enter the last names of five candidates in a local election and the number of votes received by each candidate. The program should then output each candidate's name, the number of votes received, and the percentage of the total votes received by the candidate. The program should also output the winner of the election.