[Python-Dev] Examples for PEP 572

Sven R. Kunze srkunze at mail.de
Wed Jul 4 14:32:32 EDT 2018


Sorry for adding yet another mail. :-(

On 04.07.2018 10:54, Serhiy Storchaka wrote:
> Sorry, this PEP was rewritten so many times that I missed your Appendix.
>
>> while total != (total := total + term):
>>     term *= mx2 / (i*(i+1))
>>     i += 2
>> return total
>

This very example here caught my eye.

Isn't total not always equal to total? What would "regular" Python have 
looked like?

Regards,
Sven


More information about the Python-Dev mailing list