Zig course

Zig Level 1: Zig Foundations

Zig Foundations is level 1 of 11 of the LoWisa Zig course. It has 3 lessons and 9 ideas. Below is every lesson and what it teaches, in one line each.

Updated 2026-11-25

Types and Values

  • Explicit integers. Zig integers say their width: u8, i32, u64: and arbitrary widths like u7 when hardware asks.
  • const and var. const binds immutably, var mutably: immutability the visible default.
  • No implicit coercions. Numeric conversions are explicit: @intCast and friends, every narrowing a visible decision.

Control Flow

  • if and switch. Zig branches with if and switch: switch exhaustive over enums, checked by the compiler.
  • Loops. while and for iterate: for walking slices with index and value, no hidden iterators.
  • defer. defer schedules cleanup at scope exit: release written beside acquire, run in reverse order.

Functions

  • Functions. A fn declares typed parameters and return: pub exporting it beyond the file.
  • Error unions in signatures. A return like !u32 means error-or-value: fallibility part of the type.
  • No variadics magic. Zig passes tuples and comptime where others use variadics: printing included, checked at compile time.

Before and after this level

In the app each of these ideas is taught and then asked back, and the level ends with a checkpoint and flashcards. See Checkpoints and flashcards.

Frequently asked questions

What does Zig Level 1: Zig Foundations cover?

Types and Values, Control Flow, Functions: 3 lessons and 9 ideas.

What should I know before this level?

The level before it, Start Here: Explicit Systems Programming, which covers Zig's Design Philosophy, Native Compilation.

Learn Zig on your phone

The first level is free. LoWisa is on Google Play and the App Store.