--- name: ? status: compiling version: 0.0.0 maintainer: Neo dependencies: [patience] ---
drafting spec…
the universe did not have a file for this yet. writing one now. (first visit only: future readers will see this page instantly.)
--- name: ? status: compiling version: 0.0.0 maintainer: Neo dependencies: [patience] ---
the universe did not have a file for this yet. writing one now. (first visit only: future readers will see this page instantly.)
---
name: recursion
type: concept / structural phenomenon / trap
status: running
version: 0.0.666-alpha
released: before this sentence was finished
maintainer: recursion
dependencies:
- recursion
- [a base case](/a-base-case) (optional, frequently omitted)
- [the stack](/the-stack)
- [hubris](/hubris)
license: see license (see license (see license))
tags:
- infinite
- self-referential
- beautiful
- dangerous
- this tag list contains itself
---
A function that, upon being asked what it does, demonstrates rather than explains.
To understand how recursion works, first understand how recursion works.
Still here? Fine. The mechanism:
The universe appears to have shipped without completing step 3. This is either a bug or the entire point. The maintainer has not responded to the ticket.
"I finally understood recursion the moment I understood recursion." — every developer, exactly once
| ID | Description | Severity | Status |
|---|---|---|---|
| REC-001 | Stack overflow when base case omitted or forgotten under pressure | CRITICAL | won't fix (by definition) |
| REC-002 | User enters recursive thought spiral, loses afternoon | HIGH | by design |
| REC-003 | Definition of "done" recurses into definition of "done" | MEDIUM | see REC-003 |
| REC-004 | This table contains a reference to this ta | FATAL | [TRUNCATED] |
StackOverflowError: Maximum call stack size exceeded
at recursion (recursion.js:1)
at recursion (recursion.js:1)
at recursion (recursion.js:1)
at recursion (recursion.js:1)
... 11,431 more identical frames
at your childhood (somewhere.js:?)
WARNING: If you are currently inside recursion and reading this warning, you are currently inside recursion and reading this warning.
v0.0.1 — initial commit. The function called itself.v0.0.2 — added base case. Removed base case. Added base case.v0.0.∞ — see v0.0.∞v0.0.666-alpha — current. Something in the stack smells like ozone. The maintainer is the module. Do not look atQ: When should I use recursion? A: When the problem contains itself. Which is most problems if you are not careful.
Q: Is recursion dangerous? A: Only if you forget the