Polling
The internet and the web are enabling more people to network, join a cause, voice
opinions, and so on. The presidential candidate in 2008 used the internet intensively
to get out their message and raise money for their campaigns. In this exercise, you’ll
write a simple polling program that allows users to rate five social-consciousness
issues from 1 (least important) to 10 (most important). Pick five causes that are
important to you (e.g., political issues, global environmental issues). Use a onedimensional
array topics (of type String) to store the five causes. To summarize the
survey responses, use a 5-row, 10-column two-dimensional array responses (of type
int), each row corresponding to an element in the topics array. When the program
runs, it should ask the user to rate each issue. Have your friends and family respond
to the survey, then have the program display a summary of the results, including:
A tabular report with the five topics down the left side and the 10 ratings
across the top listing in each column the number ratings received for the
topic.
To the right of each row, show the average of the ratings for that class.
Which issue received the highest point total? Display both the issue and the
point total.
Which issue received the lowest point total? Display both the issue and the
point total.