You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Print out all the state names from the csv# Coded in the "procedural" styledef get_country_name_from(line): columns = line.split(",") return columns[1]f = open('2012_US_election_state.csv', 'r')print "Opened file:"all_lines = f.readlines()for line in all_lines: print " "+get_country_name_from(line)print "done ("+str(len(all_lines))+" lines)"