I learnt of the \"exactly equal to\" operator in Erlang, which compares not only values, but also data types of numbers, and I was curious about how things work in Python an
It's a peril of using floating-point numbers.
If you need precision at this deep a level, use the Decimal type.
More here: http://docs.python.org/library/decimal.html