Azreal
New member
Ok, im having problems with one of my programs for java class. The instructions are listed here:
PROGRAM 8
Write a program that reads an expense list from the following file and prints the dollar sum of all expenses. You must use this file exactly as listed. Turn in your .java program. Absolutely no working together.
dog $9.50
cat $12.57
rat $2.18
petFood $8.69
Tacos $6.13
Soda $7.86
Shoes $5.40
Book $14.38
Burgers $8.45
Gas $5.25
Water $11.81
Electricity $10.88
Oranges $13.25
Ketchup $13.43
Salsa $14.05
Tacos $6.55
Cookies $8.37
Chicken $3.98
Cable $10.42
Phone $13.38
--------------------------------------------------------------------------------
OUTPUT
TOTAL=$186.53
Would someone mind giving me some hints on how to do this, or what would be the best way to approach it? Heh, if ya wanna give me some code samples that woudl be helpful too!
PROGRAM 8
Write a program that reads an expense list from the following file and prints the dollar sum of all expenses. You must use this file exactly as listed. Turn in your .java program. Absolutely no working together.
dog $9.50
cat $12.57
rat $2.18
petFood $8.69
Tacos $6.13
Soda $7.86
Shoes $5.40
Book $14.38
Burgers $8.45
Gas $5.25
Water $11.81
Electricity $10.88
Oranges $13.25
Ketchup $13.43
Salsa $14.05
Tacos $6.55
Cookies $8.37
Chicken $3.98
Cable $10.42
Phone $13.38
--------------------------------------------------------------------------------
OUTPUT
TOTAL=$186.53
Would someone mind giving me some hints on how to do this, or what would be the best way to approach it? Heh, if ya wanna give me some code samples that woudl be helpful too!