Sep-20-2017, 08:21 PM
(Sep-20-2017, 12:40 AM)JinLee Wrote: Python 3 resolved it! Funny how there are differences with syntax between the two versions.
In python2,
input()
will call eval()
on whatever you type in, which is incredibly bad. In python3, input()
was removed completely, and replaced with what used to be raw_input()
, since that's what 99.9% of people want to be using anyway.That fixed it for you, because when you type a number, it'd get passed to eval() in python2, and would then be a number, instead of a string. In python3, anything from input() is always a string.