def createCounter(): i = 0 def counter(): nonlocal i i = i +1 return i return counter
Sign in to make a reply
祥子920