Advertisement
Guest User

Untitled

a guest
Jun 26th, 2019
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.32 KB | None | 0 0
  1. import something
  2. import another thing
  3.  
  4. def main():
  5. bar = foo()
  6. print("the answer is {}".format(bar))
  7.  
  8. def foo():
  9. return 42
  10.  
  11.  
  12. # this makes sure the main function will only be executed
  13. # when using your .py file as a script, not when importing
  14. # it as a module.
  15. if __name__ == "__main__":
  16. main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement