Functions

Students will ...

  1. be able to describe the semantics of a function definition -- what a function definition is and what it is good for.
  2. know the proper syntax of a function definition, including the names of the various parts.
  3. be able to describe what arguments, parameters, and formal parameters are.
  4. be able to distinguish between a function definition and a function call.
  5. be able to define a function that returns a value to its caller (a fruitful function).
  6. understand that the return statement specifies the value to return to the function caller.
  7. know that a function that does not execute a return statement returns None.
  8. be able to describe what a variable's scope or lifetime is (i.e., for a local variable or parameter).
  9. be able to recognize and implement an accumulator pattern.
  10. be able to articulate the multiple benefits of defining functions.
  11. be able to trace the flow of execution of a series of function calls.