cleaner way to write this?

Paul Rubin http
Wed Oct 25 17:47:08 EDT 2006


Bruno Desthuilliers <bdesth.quelquechose at free.quelquepart.fr> writes:
> > But if the user doesn't enter any text, I don't want the method to
> > return at all (even None).
> 
> John, please re-read the FineManual(tm). None is the default return
> value of a function - even if there's no return statement.

Correct, but if the user doesn't enter text, the function is supposed
to loop and prompt for text again, instead of returning.



More information about the Python-list mailing list