Tip Calculator Formula
Understand the math behind the tip calculator. Each variable explained with a worked example.
Formulas Used
Tip Amount
tip_amount = bill_amount * tip_percent / 100Total with Tip
total_bill = bill_amount + tip_amountPer Person
per_person = total_bill / num_peopleVariables
| Variable | Description | Default |
|---|---|---|
bill_amount | Bill Amount(USD) | 85 |
tip_percent | Tip Percentage(%) | 18 |
num_people | Number of People | 2 |
How It Works
How Tips Are Calculated
Tip = Bill × Tip% / 100
Total = Bill + Tip
Per Person = Total / Number of People
Common Tip Percentages
Worked Example
$85 dinner bill, 18% tip, split between 2 people.
bill_amount = 85tip_percent = 18num_people = 2
- 01Tip = $85 × 18% = $15.30
- 02Total = $85 + $15.30 = $100.30
- 03Per person = $100.30 / 2 = $50.15
Ready to run the numbers?
Open Tip Calculator