Antoine Pitrou wrote: [...]
It might be the integer 1 or the string "1". You need repr() to tell the difference.
Antoine, that's a cheap shot. The *very next paragraph* of my post which
you replied to, and which you snipped out of your response, says:
I am aware that the string representation (using either __str__
or __repr__) of an object is not the definitive word in what
the object really is. Using just print, one can't distinguish
between a class and a string "