Defining and Calling Python Functions

0%

Consider a short example script that defines a function f() and prints debug information with print():

Python
def f():
    print("Function called")

print("Before calling f()")

f()

print("After calling f()")

In what order do outputs appear?

Select one:

Think about when a function body gets executed, and where execution returns after a function finishes.

Sorry! There has been an error processing your answer. Please try again.

Got feedback on this question?