And Operator Bool_4 is giving me issues


#1



I am working on And Operator, and I have tried it in a lot of different ways.

I write: 
'bool_one = False and False is False

bool_two = -(-(-(-2))) == -2 and 4 >= 16**0.5 is False

bool_three = 19 % 4 != 300 / 10 / 10 and False is True

bool_four = -(1**2) < 2**0 and 10 % 10 <= 20 - 10 * 2 is True

bool_five = True and True is True'

It gives me this response: 'Oops, try again. Double check your value for bool_four!'

I have no idea what I am doing wrong; I have tried putting false, and that doesn't work either

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


#2

@samthomasson,
I agree that the Oops-message is mislaeding you......
as the real problem lies in your bool_three evaluation !!!!!


#3

It didn't work. Thanks for pointing that out, and I fixed it, but I still get the message about bool_four


#4

@samthomasson,

Add following code and look at the result

bool_one = False and False

bool_two = -(-(-(-2))) == -2 and 4 >= 16**0.5

bool_three = 19 % 4 != 300 / 10 / 10 and False


bool_four = -(1**2) < 2**0 and 10 % 10 <= 20 - 10 * 2

bool_five = True and True

print("{} {} {} {} {}".format(
    bool_one,
    bool_two,
    bool_three,
    bool_four,
    bool_five))

======================================

You might try using

bool_four = (-(1**2) < 2**0 and 10 % 10 <= 20 - 10 * 2) is True

#6

Thank you! I spent many frustrated hours on this and was about to give up when I found your post which helped me immensley!

Thanks!