Build a Travel Weather Planner - Build a Travel Weather Planner

Tell us what’s happening:

O que há de errado com esse código?
Por que dá esse erro de sintaxe?

Your code so far

distance_mi = 7
is_raining = True
has_bike = False
has_car = True
has_ride_share_app = False

if distance_mi == False:
    print ("False")

if distance_mi <= 1 and not is_raining:
    print ("True")
elif:
    print ("False")

    

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/148.0.0.0 Safari/537.36

Challenge Information:

Build a Travel Weather Planner - Build a Travel Weather Planner

Hi @isalauf.racanelli,

Here’s an excerpt from this theory lecture: Booleans and Conditionals - How Do Conditional Statements and Logical Operators Work? | Learn | freeCodeCamp.org

There might be situations in which you want to account for multiple conditions. To do that, Python lets you extend your if statement with the elif (else if) keyword.

Here’s the syntax:

if condition1:
   pass # Code to execute if condition1 is True
elif condition2:
   pass # Code to execute if condition1 is False and condition2 is True
else:
   pass # Code to execute if all conditions are False

Happy coding!

Tell us what’s happening:

Eu não estou conseguin conclur os ultimos 3 passos, onde eu errei?
O que deveria fazer para que desse certo?

Your code so far

distance_mi = 7
is_raining = True
has_bike = False
has_car = True
has_ride_share_app = False

if distance_mi == False:
    print ("False")
elif distance_mi <= 1 and not is_raining:
    print("True")
else:
    print ("False")



    

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/148.0.0.0 Safari/537.36

Challenge Information:

Build a Travel Weather Planner - Build a Travel Weather Planner

I went ahead and combined your posts for you. In the future, just reply to the original thread to add further updates.

Implement all of the user stories as asked. Then change the values of your variables so you can test that each scenario returns what is expected. Currently, you have distance_mi set to 7, but you have not written code for that yet.