1. Many commentators today say only a few “Swing states” (states where voters are almost equally divided among Republicans and Democrats) are determining the election.
States with heavy majorities of Republicans or Democrats are less important due to the Electoral college versus the Popular Vote.
Write a two page essay on your evaluation of the statement “Only Swing States matter”, using the election data available in the Election data files provided.
Consider how many “swing states” there are, if these states change the party they vote for often.
Does your data compare with published new articles about this subject?
Your submission should include at least the following:
-A clear description of your approach to evaluating the statement
-Some statistics generated by a program you wrote using the election data
-A reference to news sources about this topic
2. Write a program that uses the file ElectoralVotes.csv and the file Election Data 2012 to calculate the number of electoral votes earned by Obama and Romney in the 2012 election.
Your program should build a lookup table with the state names, another table with the associated electoral votes for that state.
The output should show two numbers – the total electoral votes earned by each candidate.
And print each state’s name, the winner, and number of electoral votes won.

Solution Preview

This material may consist of step-by-step explanations on how to solve a problem or examples of proper writing, including the use of citations, references, bibliographies, and formatting. This material is made available for the sole purpose of studying and learning - misuse is strictly forbidden.

import java.util.ArrayList;
import java.util.Scanner;

* @author
public class Election {
    public static void main(String[] args) {
       ArrayList<ElectionData> eds = new ArrayList<>();
       ArrayList<ElectionVotes> evs = new ArrayList<>();
       readElectionData(eds, "ElectionData2012.csv");
       readElectionVotes(evs, "ElectionVotes.csv");
       showResult(eds, evs);

This is only a preview of the solution. Please use the purchase button to see the entire solution


or $1 if you
register a new account!

Assisting Tutor

Related Homework Solutions

Get help from a qualified tutor
Live Chats