"Cecilia Alm" <[EMAIL PROTECTED]> wrote
> functions which lack a return statement ('procedures') actually
> return "None".
> For such functions, I assume it's preferred to not catch "None" in a
> variable.
You can catch it if you like, but since functions with no return
*always* return None the
OK, that's my opinion too.
Thanks!
2007/4/24, Andre Engels <[EMAIL PROTECTED]>:
> My opinion is that one should not create or set a variable if its
> value is not used. In the case mentioned, you know what the return
> value will be, so there seems to be no reason to keep it.
>
> 2007/4/24, Cecil
My opinion is that one should not create or set a variable if its
value is not used. In the case mentioned, you know what the return
value will be, so there seems to be no reason to keep it.
2007/4/24, Cecilia Alm <[EMAIL PROTECTED]>:
> My apologies for asking a trivial question about programming
My apologies for asking a trivial question about programming practice.
As mentioned in the online tutorial
(http://docs.python.org/tut/node6.html#SECTION00670),
functions which lack a return statement ('procedures') actually return "None".
For such functions, I assume it's preferre