Tell us what’s happening:
my code is the same as some of the other people that have there’s working but when i check my code i get this error message “You should use the round() function to round final_bill to two decimal places and assign the result to your each_pays variable.” can someone please help me find the problem
Your code so far
running_total = 0
num_of_friends = 4
appetizers = 37.89
main_courses = 57.34
desserts = 39.39
drinks = 64.21
running_total += appetizers + main_courses + desserts + drinks
print('Total bill so far:', running_total)
tip = running_total * 0.25
print('Tip amount:', tip)
running_total += tip
print('Total with tip:', running_total)
final_bill = running_total / num_of_friends
print('Bill per person:', final_bill)
# whats happening
# User Editable Region
final_bill = 62.13437499999999
round(final_bill, 2)
each_pays = 62.13
print('Each person pays:', each_pays)
# User Editable Region
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:154.0) Gecko/20100101 Firefox/154.0
Challenge Information:
Build a Bill Splitter - Step 8