Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def a():
- exec("AD = (1,2,3,4,5,6);")
- for i in AD:
- print(i)
- a()
- --------------
- linux-xk05:/home/zenix/Desktop # python3 py.py
- Traceback (most recent call last):
- File "py.py", line 6, in <module>
- a()
- File "py.py", line 3, in a
- for i in AD:
- NameError: name 'AD' is not defined
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement