Recursion Basics

Define a solution in terms of itself with a base case.

Lesson 12 of 20
55%

Concept

A recursive function calls itself on smaller inputs until a base case. Ensure progress toward base and consider stack depth limits.

Recursive Thinking

Identify base case
Reduce problem
Call recursively
Combine results