On 24/04/2018 02:42, Chris Jerdonek wrote:
That's good. It also makes it natural to expect only a simple name. One can "define" a name, but assignment to a complex left-side expression is not definition (binding).On Mon, Apr 23, 2018 at 4:54 PM, Greg Ewing <[email protected]> wrote:Tim Peters wrote:if (diff := x - x_base) and (g := gcd(diff, n)) > 1: return gMy problem with this is -- how do you read such code out loud?It could be..."if diff, which we define as x - x_base, and g, which ....." etc.
Jeff Allen
_______________________________________________ Python-Dev mailing list [email protected] https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com