Beginning Python - Booleans

I can’t get Next.Tech to accept any of my code… am I missing something glaringly obvious?

Thanks for your help!! Boolean Question.png

It is unfortunate that they cannot be more specific about what is “correct”.

Two suggestions come to mind:

  1. python doesn’t require parentheses in if statements (unlike other languages). So you can try 

    if string1 != string2 :

  2. The result of the “!=” operation is a boolean. They may be jumping ahead a bit and expecting you to realize that. So you can try

    my_boolean = string1 != string2

1 Like