The most common answer is:
brought_food = True
brought_drink = False
These lines don’t work! Fix them so that they do.
print “Did the person bring food? ” + str(brought_food)
print “Did the person bring a drink? ” + str(brought_drink)
To fix the the code so that it works correctly in Python, especially in Python 3, you need to use parentheses around the arguments to the print
function.
Here’s the corrected version of the code:
brought_food = True
brought_drink = False
# Corrected lines with proper Python 3 syntax
print("Did the person bring food? " + str(brought_food))
print("Did the person bring a drink? " + str(brought_drink))