Skip to content

Instantly share code, notes, and snippets.

@acbart
Created February 16, 2018 01:40
Show Gist options
  • Save acbart/8c13b0efb6e1b863f9c72e9288e0d5b0 to your computer and use it in GitHub Desktop.
Save acbart/8c13b0efb6e1b863f9c72e9288e0d5b0 to your computer and use it in GitHub Desktop.
What will be printed?
# Code without call outside, without call inside
def a():
print("a() was called")
# Code without call outside, with call inside
def b():
print("b() was called")
b()
# Code with call outside, without call inside
def c():
print("c() was called")
c()
def d():
print("d() was called")
d()
d()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment