help with code
I am getting an error with this code when I try to compile it. It had to do with the { after the public class Purse thing. I am sure thats not all that is wrong with this code. Can anyone help me?
public class Purse
{
//Instance Fields
private static final double Dollars=1.00;
private static final double Quarters=0.25;
private static final double Dimes=0.10;
private static final double Nickles=0.05;
private static final double Pennies=0.01;
private double totalvalue;
public Purse ()
{
totalvalue=0;
}
public void addDollars ( double amount)
{
double total=Dollars * amount;
doll=total;
}
public void addQuarters (double amount)
{
double total=Quarters * amount;
quar=total;
}
public void addDimes (double amount);
{
double total=Dimes * amount;
dim=total;
}
public void addNickles (double amount)
{
double total=Nickles * amount;
nick=total;
}
public void addPennies (double amount);
{
double total=Pennies * amount;
penn=total;
}
public double getTotalValue
{
double totalvalue=doll + quar + dim + nick + penn;
return totalvalue;
}
}

