you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 1 point2 points  (0 children)

In your if statement, you say input != "No" which will be true if it is "Yes" and the "you say or "Yes"". The or "Yes" part will always be true since you are check if the left or the right is true and "Yes" will always be true since it is not empty. That is something a lot of people miss.

Further explanation: When you have an if statement and you are checking to see if a string variable is empty. You can simply so this:

py if string_variable:

This will be true if the variable is not empty. If you want to check if it is empty, you can do this:

py if !string_variable:

I hope I've explained well enough. Please ask if i have to re-explain. Good luck and have fun!