Build a Bill Splitter - Step 4

Tell us what’s happening:

Not sure what’s wrong in my code.
Everything looks to check out.

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: " + " " + 
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

Your print statement should be formatted as: print("string", variable) to pass the tests.

1 Like

Got it, good catch. Commas = spaces.

Well, no, but the instructions don’t make it clear that two arguments are expected to be used in the print statement. The good news is that a fix is in the works. Until then, make sure you print with that format in the next steps, too.

1 Like

Hi there sorry for asking on the solution I tried this and it seems I still do not get it correct so I am unsure what to do

This is what I have and when I convert the last part in a string is still does not do anything ?
print("Total bill so far: ") + (running_total)

hi @adriaan.j2003 , please create your own topic to ask for help, but also notice how your code does not match the pattern mentioned of print("string", variable)

If you have a question about a specific challenge as it relates to your written code for that challenge and need some help, click the Help button located on the challenge.

The Help button will create a new topic with all code you have written and include a link to the challenge also. You will still be able to ask any questions in the post before submitting it to the forum.

Thank you.