Skip to content Skip to sidebar Skip to footer

Unboundlocalerror: Local Variable 't' Referenced Before Assignment | Already Defined

I'm getting the error: UnboundLocalError: local variable 't' referenced before assignment When I'm performing the equation t = t + tc in a function. This doesn't seem to be make a

Solution 1:

global works per function - so you have to mark the variable as global on every function you use it.


Post a Comment for "Unboundlocalerror: Local Variable 't' Referenced Before Assignment | Already Defined"