Arnaud Delobelle:
> In this case why not:
>
> def xfib(a=1, b=1):
>     while True:
>         yield a
>         a += b
>         yield b
>         b += a

That's a bit less easy to understand than my version, for me.
In my version is easy to see the values of the variables. And using a
longer function name is better.

Bye,
bearophile
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to