Two Centuries of Elixir
- Published
- Jun 01, 2026
- Reading time
- 1 min
| Name | Description | Effort |
|---|---|---|
| PART I | CORE ELIXIR & THE BEAM | |
| Phase 1 | Functional Foundations | |
| 1. Roll your own Enum |
Reimplement map, reduce, and filter from scratch with tail recursion, then benchmark them against the built-in Enum.
|
low |
| 2. Lazy infinite sequences |
Build an endless primes or Fibonacci generator with Stream.unfold/2 and pull finite slices with Enum.take/2.
|
low |
3. with pipelines
|
Chain several functions that each return {:ok, _}/{:error, _} using with, so the flow short-circuits on the first error.
|
low |
| 4. Comprehension depth |
Use a for comprehension with multiple generators, guard filters, and :into to build a map or MapSet in one pass.
|
low |
| 5. Lazy file pipeline |
Stream a multi-GB file through File.stream! and Stream transforms so it's processed line-by-line and never fully loaded.
|
low |
| 6. Protocols |
Define a Describable protocol, implement it for a few different structs, and add an Any fallback for everything else.
|
med |
| 7. Custom Enumerable |
Implement the Enumerable protocol for a ring-buffer struct so Enum and Stream functions work on it.
|
med |
| 8. Custom Collectable |
Implement the Collectable protocol for a struct so Enum.into/2 can build it from any enumerable.
|
med |
| 9. Custom Access |
Implement the Access behaviour for a struct so get_in, put_in, and update_in can traverse it.
|
med |
| 10. Behaviours |
Define a behaviour with @callbacks and write two swappable adapter modules that implement it (e.g., two storage backends).
|
low |
| 11. Persistent structure | Implement an immutable zipper or finger tree that supports efficient local updates without copying the entire structure. | high |
Some rich text.