small program with strange behavior

Peter Hansen peter at engcorp.com
Sun Nov 23 09:36:15 EST 2003


Dan Stromberg wrote:
> 
> The below small program is giving strange behavior.  At the bottom of the code,
> please find "this works" and "this doesn't work" comments.  Why does one
> work and the other not?

You might find people more willing to respond if you (a) shorten your
not-so-small code down to the smallest size that reproduces the problem
you are seeing, and (b) define more clearly what "this works" and "this 
doesn't work" actually mean.  Are you getting exceptions?  Some functionality
that is not doing the right thing? (If so, maybe tell people what the darn
thing is supposed to do rather than making them guess.)

Some people might read all that, execute it, etc, but most of us
don't have time.

-Peter




More information about the Python-list mailing list