Is there a way to reference the variable being assigned to after the = in python? Similar to += -


python has +=, -=, *=, %=, etc. there generic form of this? first thing thought try was:

x = _ + 1 

as generic version of x+=1. curious actual code looks right now:

a = x[y][z] x[y][z] = f(a) 

and x[y][z] = f( _ ) made sense in head, maybe want there, isn't. there similar in python?

no, there's not, sorry. i've wished many times myself.


Comments