Here is my code. All help will be greatly appreciated. PS I'm not making a scam or anything like that, the top part is supposed to be a joke.
import java.io.; import java.util.;
public class ShoppingSpree//Nick
{
public static void main(String args[])
{
int maxitems = 3;
double damountofmoneywon = 100.00;
double moneyleft = damountofmoneywon;
for(moneyleft = 100.00; moneyleft == 0.00;)
{
System.out.println("You have won $100 for being the 1,000,000 visitor to this site.");
System.out.println("You may buy up to 3 items costing no more than $100.");
System.out.println("Enter the cost of your item: ");
Scanner itemonecost = new Scanner(System.in);
double ditemonecost = itemonecost.nextDouble();
if(ditemonecost <= moneyleft)
{
System.out.println("You have enough money for this item.");
moneyleft = moneyleft - ditemonecost;
}
else if(moneyleft == 0)
{
System.out.println("You have no more money");
break;
}
else
{
System.out.println("You don't have enough money, try again");
}
}
}
}