10. Mix n Match Problems


#1



Not sure what's wrong... Error says 'Oops, try again. Make sure you have a value for all 5 variables!'

https://www.codecademy.com/courses/python-beginner-BxUFN/2/6?curriculum_id=4f89dab3d788890003000096#


# Use boolean expressions as appropriate on the lines below!

# Make me false!
bool_one = (2 <= 2) and "Alpha" == "Bravo"  # We did this one for you!

# Make me true!
bool_two = (1 == 1) or "Charlie" == "Crown"

# Make me false!
bool_three = (2 == 3) not 1 < 2

# Make me true!
bool_four = (7 == 21 / 3) and 4 <= 4

# Make me true!
bool_five = (9 == 81 / 9) or 9 >= 9


#2

this one contains invalid syntax:

bool_three = (2 == 3) not 1 < 2

not means the output is reversed (true becomes false and vice versa) but you have two conditions here which means you should also use and or or


#3

So like this?

# Use boolean expressions as appropriate on the lines below!

# Make me false!
bool_one = (2 <= 2) and "Alpha" == "Bravo"  # We did this one for you!

# Make me true!
bool_two = (1 == 1) or "Charlie" == "Crown"

# Make me false!
bool_three = (2 == 3) not (1 < 2) or (2 < 1)

# Make me true!
bool_four = (7 == 21 / 3) and (4 <= 4)

# Make me true!
bool_five = (9 == 81 / 9) or (9 >= 9)

#4

no, like this:

(2 == 3) or not (1 < 2)

you already had two conditions


#5

Hey thanks a lot buddy!
I was having the same issues, myself. Hopes this helps out the thread creator too.

Cheers!


#6

Thanks for helping <3