Strange side effect from reading a list of numbers from argv

Greg Ewing greg.ewing at compaq.com
Mon Jul 19 16:57:07 EDT 1999


Jeff Epler wrote:
> 
> It's come up before that "string <
> int" doesn't cause an exception, but I don't remeber what the good reason
> for it was.

The reason is so that the built-in sort method
will work on a list of differently-typed objects.
Whether this is a "good" reason is a matter
of opinion...

Greg




More information about the Python-list mailing list