So basically what i want wanting to do is import a csv file and then have the user specify what year they want to add up all the total revenue.
here is what is in my csv file
2009|1|22|56.23
2009|4|12|86.24
2009|5|20|34.67
2009|6|22|12.67
2009|3|21|795.12
2008|7|4|753.43
2008|8|9|2345.45
2008|9|1|2357.23
2010|5|2|7552.21
2010|3|15|666
2010|4|17|2323.75
2010|5|19|2367.23
2010|6|25|6453
2010|2|6|1267.12
import csv
print ("Enter the year you want to add up the total revenue.")
reader = csv.reader(open("/revenue.csv", "rb"))
for row in reader:
print(row)
here is what i have so far...sorry i am very new to python but am really enjoying it. any help would be greatly appreciated.
thanks
keith