Skip to content

Instantly share code, notes, and snippets.

@rogerwschmidt
Last active October 24, 2018 20:08
Show Gist options
  • Save rogerwschmidt/ed90a98e148a82a3ebd0bec299fae0fc to your computer and use it in GitHub Desktop.
Save rogerwschmidt/ed90a98e148a82a3ebd0bec299fae0fc to your computer and use it in GitHub Desktop.

Recursion Instructor Notes

Objectives

  • Describe what recursion is
  • Enumarate the two parts of a recursive function
  • Convert from iteration to recursive

What is recursion?

  • With your table, create a definition of what recursion is.

What are the two parts of a recursive function?

  • With your table, name the two parts of a recursive function.

Convert the following problems to recursive.

  • Add the total length of all string in an array
  • Keep all the strings up to a certain length from an array
  • Find the longest string in an array
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment