Chapter 11: More on Functions

Learning Objectives

Upon completing all the content in this chapter, you should be able to do the following:

  1. Create and use anonymous functions
  2. Explain how an anonymous function can be called, even though it doesn’t have a defined name
  3. Explain common uses of anonymous functions
  4. Use recursion to create algorithms that solve recursive problems
  5. Use functions as input parameters to other functions
  6. Describe the concept of a recursive problem, including the definitions of base case and recursive case
  7. Explain how base cases are important in preventing infinite recursion

Key Terminology

Here is a list of key terms for this chapter broken down by the page the term first appears on. You should make note of these terms and their definitions.

Functions as Values

  1. function; as a value

Passing Functions as Arguments

  1. setTimeout
  2. map

Recursion

  1. recursion

Recursion Walkthrough: The Base Case

  1. base case