is there a shorter way to write this

Tim Chase python.list at
Thu Jan 29 16:03:50 CET 2009

> Hmm, sounds like homework, but I'll bite.

The underlying problem does sound like homework, but the OP 
posted a working solution, and was only looking for ways to 
improve it.  So I'm a little more lenient on providing 
alternatives.  It's true that the homework problem may have been 
exactly as posted ("Improve this code"), but that's less likely 
in my estimation.


More information about the Python-list mailing list