Build a Bill Splitter - Step 4

Tell us what’s happening:

I cannot make it through. Please, could you help me with the task?
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: ’ + str(running_total))

Your code so far

running_total = 0

num_of_friends = 4

appetizers = 37.89
main_courses = 57.34
desserts = 39.39
drinks = 64.21


# User Editable Region

running_total = appetizers + main_courses + desserts + drinks

print('Total bill so far: ' + str(running_total))

# User Editable Region

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/145.0.0.0 Safari/537.36

Challenge Information:

Build a Bill Splitter - Step 4

Yeah, this step is a little quirky. The tests are looking for two arguments in your print function (the space should come before the second argument)…and you were not asked to apply the str() method to running_total.

Do you mean like this?

running_total = appetizers + main_courses + desserts + drinks

print(‘Total bill so far:’ + ’ ’ + {running_total})

1 Like

im stuck on this aswell

1 Like

No. More like this: print("my string", myVariable)

1 Like

Here’s the tip:

running_total = appetizers + main_courses + desserts + drinks

removed by moderator

1 Like

Thank you so much, it worked! :slight_smile:

thank you ………………………………..

1 Like

Congratulations on solving the challenge! You should be proud of your achievement…we are! But we are removing your working solution, so it is not available to others who have not yet done the work to get there. Again, congrats!

2 Likes

In the future, please create your own topic when you have specific questions about your own challenge code. Only respond to another thread when you want to provide help to the original poster of the other thread or have follow up questions concerning other replies given to the original poster.

The easiest way to create a topic for help with your own solution is to click the Ask for Help button located on each challenge. This will automatically import your code in a readable format and pull in the challenge url while still allowing you to ask any question about the challenge or your code.

Thank you.

1 Like

That’s not “quirky”; that’s expecting us to have information that’s not in the task.

we are working on improving this task, meanwhile it’s quirky like that

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.