# a function definition typically looks like this: def func(): # No parameters # do this ... def func (x): # One Parameter x ... def func(x, y, z): # Parameter list x, y, z ... # Scope is literally like the # scope of where you use something. # in a function what that means is # everything you want the function to # do is indented into it right? # so everything within the function # is known within the SCOPE of the # function def func1(): local_variable = 1 # local_variable is within the func scope # I can't use local_variable anywhere # outside this function because Pycharm # won't know what it is. # local_variable # uncomment that ^ notice how python doesn't # know what it is # Invocation means I'm calling a function. # I want the function to execute. def f(x): return x b = f(3) # this is a function invocation # because we are calling f(x) # Parameter passing is the act of when # a function is invoked, a COPY of its # arguments is passed, given to # the function to start running and its # parameters are going to be initialized # with copies of the arguments. # So in my example, 3 is the argument # and is used to initialize parameter x # in the function. # The inability to write a swap function # has been a common theme on previous tests # Importing a file # usually means you're # importing a module # in this class. # what that means is # modules have the # function definitions # and we want to be able to use # the functions FROM that module