Oct-10-2016, 06:03 PM
I'm not getting that error, at least not in Python 3.5. Note, however, that variables have scope. The logged_in variable in your login function only works within that function, it doesn't modify the logged_in variable on line 2. It's the difference between function scope and module scope. I would suggest using return values to modify the outer logged in variable.
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures