Guest User

Untitled

a guest
Nov 17th, 2018
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.33 KB | None | 0 0
  1. main.py:
  2.  
  3. # The variable that has to be set for mymodule to work
  4. X = 2
  5.  
  6. import mymodule
  7.  
  8. mymodule.py:
  9.  
  10. print(X)
  11.  
  12. Fel:
  13.  
  14. Traceback (most recent call last):
  15. File "main.py", line 5, in <module>
  16. import mymodule
  17. File "/home/jon/tmp/mymodule.py", line 2, in <module>
  18. print(X)
  19. NameError: name 'X' is not defined
Add Comment
Please, Sign In to add comment