-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
18 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# Recursion | ||
|
||
* A process (a function) that calls itself. | ||
|
||
## The call stack | ||
* It's a stack data structure. | ||
* Any time a function is invoked it is placed (pushed) on the top of the call stack. | ||
* When JavaScript sees the return keyword or when the function ends, the compiler will remove (pop) | ||
|
||
## How recursive functions work | ||
* Invoke the same function with a different input until you reach your base case! | ||
|
||
## Base Case | ||
* The condition when the recursion ends. | ||
|
||
## Two essential parts of a recursive function! | ||
* Base case | ||
* Different Input |
File renamed without changes.