jonnifyelixir
Course / F3 · The Elixir Language

Chapter F3 · nine modules

The Elixir Language

F2 argued that programs are pure transformations of immutable data, composed into pipelines. This chapter is where that argument becomes a working language: the syntax, the data, and the runtime that make those ideas the path of least resistance.

Elixir is a young language on an old, battle-tested machine. Before the lessons begin, three short readings set the scene: who built it and why, how it has grown release by release, and what actually happens when your source becomes bytecode on the BEAM. Then the nine modules run from the values you type into the shell, through pattern matching and modules, to processes and OTP.

source.ex AST + macros BEAM bytecode

The arc of the chapter

Nine modules in three movements. Foundations cover the everyday syntax: values and the shell, the match operator, and how code is organised into modules. Data & shape are the tools for working with collections and giving data a form — enumerables and streams, structs, and protocols. Concurrency is what the BEAM is for: processes, OTP, and a playground where you watch messages arrive.

Select a stop on the path to see what it covers.

The journey · select a module

FOUNDATIONS DATA & SHAPE CONCURRENCY 1 values 2 match 3 modules 4 enum 5 structs 6 protocols 7 processes 8 OTP 9 playground start here lab
Values, types & IEx

The data you build with; the shell as a tool.

F3.01 · module Foundations available now

The chapter is one line of reasoning: learn the syntax and data, give that data shape, then put it to work across processes — the thing the BEAM was built to do.

Before the lessons

Three short readings give the language its context. They are optional, and you can skip straight to the first module — but each one makes the rest of the chapter read more easily.

Reading 1
A short history

Why José Valim built a new language on a thirty-year-old VM.

Reading 2
The release timeline

From the first commit to today, one headline per milestone.

Reading 3
Under the hood

Source to bytecode: tokens, the AST, macros, and the BEAM.

The nine modules

Foundations

F3.01 · Values, types & IEx — start here
The data you build with; the shell as a tool.
F3.02 · Pattern matching & the match operator — available
= is a match, not assignment.
F3.03 · Functions, modules & the pipe — available
Defining and composing in modules.

Data & shape

F3.04 · Enumerables & streams — available
Eager versus lazy traversal.
F3.05 · Structs, maps & keyword lists — available
Shaping data; when to use which.
F3.06 · Protocols & behaviours — available
Polymorphism and contracts.

Concurrency

F3.07 · Processes & the actor model — available
spawn, send, receive; isolation.
F3.08 · OTP: GenServer & supervisors — available
Stateful servers and fault tolerance.
F3.09 · The process playground — available · lab
Spawn processes, send messages, watch the mailbox live.

Where this sits

F3 is the third of six chapters. It follows F1 · Algebra and F2 · Functional Programming, which built the ideas as mathematics and as a style; here those ideas become the concrete language. It precedes F4 · Algorithms & Data Structures, where the language does real work, and the later chapters on pragmatic engineering and Phoenix. Read in order, each chapter is a consequence of the one before.

Begin with F3.01 — Values, types & IEx, or read the short history first for context.