6. Modules

Level: beginner · Reading time: 3 min · Prerequisite: book/poche/05-structures.html · Last review: 2026-05-09

TL;DR (5 lines)

  • Read the core idea first.
  • Understand one concept at a time.
  • Run small examples.
  • Fix errors early.
  • Move to next chapter only when clear.

Frequent mistakes

  • Skipping prerequisites.
  • Reading without trying examples.
  • Fixing too many errors at once.

Prerequisites: book/poche/05-structures.html. See also: book/chapters/09-modules.html.

Goal

Separate code into readable files/modules.

Example

space app/math
share add

Why it matters

A clear module reduces conflicts and speeds up navigation.

Quick check

What would you name the module that manages users?

Try this

  1. Create a module app/math.
  2. Export a procedure.
  3. Use it from main.

If you're stuck

Name the modules by business domain, not by generic “util”.

See also

Next best action

Apply one idea from this chapter in a tiny example, then continue.