and unless you did not show the whole code, you should get a NameError with the second. It is checking if the variable name is equal to the variable name. Since you did not create a variable name, you should get a NameError. Whereas the first one is comparing the strings.