0
2

[–] ElementalPee 0 points 2 points (+2|-0) ago 

It sounds like maybe you're not including the cost of the original meal in your total. There are a couple ways to do that. You could just add in the original meal price at the end, or you could multiply it by 1.0675 instead of 0.0675.

0
0

[–] Grospoliner ago 

Are you adding a 1 before your % increases?

Meal = 44.5
Tax = 6.75%
Tip = 15%

That would return a cost of:
44.50(1.0675) = 47.5
47.5(1.15) = 54.6 (for tipping on tax)

or

47.5 + 44.5(.15) = 54.175 (for tipping on meal)

0
0

[–] rocketmaster [S] ago 

Here's the "hint" i was given:

Let's see: meal * tax will give you the number of tax dollars to put on your bill, and meal + that number will give you the cost of the meal + tax!

The interpreter will evaluate the right-hand side of the equation first. It will ask itself, "What's meal * tax?" Once it does this and gets the result (about 3.00), it will ask itself, "What's meal + this number?" (44.50 + about 3.00 = about 47.50.) Finally, it'll move to the left-hand side of the equation and say, "Oh man, I should totally reassign meal (which was 44.50) to this new value of about 47.50." And that's how meal gets reassigned!

0
0

[–] Schrodingers_Spy ago 

Can confirm - I've done this lesson, and it's operator error.

Double check the instructions - and your code. If you continue to get stuck, you can post your code here or there.

0
0

[–] ElementalPee ago 

Would you mind pasting the exact assignment wording? Something seems off here. $47.50 looks like it would be the right total for the meal and the tax but adding in the tip puts it over. Even just the meal plus tip, completely ignoring the tax, puts it over $51.

0
0

[–] rocketmaster [S] ago 

Did i mention i was supposed to reassign the value of meal, too?

0
0

[–] MagicalCentaurBeans ago 

CodeAcademy has a lot like this. Ambiguous and somewhat pointless. There is a correct answer, and when you find out what it is, you're going to feel shafted. Like when your big sister would ask if you wanted to go to the theme park and you scream "yes!" and she shoots back "today's opposite day"

0
0

[–] european ago 

Is tip based on pre tax?