def func(): def nested_func(): n = 0 while n: print("spam")