Learn Norm
Each lesson introduces one feature through a runnable program, its checked output, an explanation, and one change to try. Follow the order for a gradual start, or open a specific topic.
The full learning path is checked against the development toolchain. Use Status and the version index to check the capabilities of an installed release.
Write and run a program
| Lesson | New feature |
|---|---|
| 01 Program entry | Start a single-file program with main() |
| 02 Explicit types and assignment | Declare and update typed variables |
| 03 Type inference | Let an initializer determine a local type |
| 04 String interpolation | Place expressions inside strings |
| 05 Operators and comparisons | Compute numbers and Boolean results |
| 06 Conditional execution | Choose a block with if/else |
Organize calculations with functions
| Lesson | New feature |
|---|---|
| 07 Functions and explicit returns | Name a calculation and return its result |
| 08 Named arguments | Bind call values to parameter labels |
| 09 Default arguments | Omit an argument with a declared default |
| 10 Argument shorthand | Reuse matching local and parameter names |
11 if as a result | Return a value from either branch |
| 12 Final-expression returns | Use the last expression as a function result |
Work with collections and control flow
| Lesson | New feature |
|---|---|
| 13 Lists | A list stores an ordered sequence whose length can change. |
| 14 Iteration | Use for to visit each element without managing an index yourself. |
| 15 Conditional loops | A condition-style for repeats while its Boolean condition remains true. |
| 16 Break | A valueless break leaves the current statement loop immediately. |
| 17 Continue | continue skips the rest of one iteration and proceeds to the next. |
| 18 Arrays | An array is indexed like a list but keeps a fixed length. |
| 19 Maps | A map associates a typed key with a typed value. |
| 20 Sets | A set keeps distinct elements and answers membership queries. |
| 21 Collection value semantics | Assigning a built-in collection gives the new binding an independent container value. |
22 Collection for elements | A collection literal can generate elements from another iterable. |
23 Collection if elements | A collection literal can include an element only when a condition holds. |
| 24 Spread in collections | ... inserts the elements of an iterable at one position in a collection literal. |
Model values and entities
| Lesson | New feature |
|---|---|
| 25 Value declarations | A value groups immutable fields into a typed data value. |
| 26 Value equality | Values compare by their contents rather than by creation event. |
| 27 Class declarations | A class models an entity with fields and behavior that can change. |
| 28 Class identity | Class variables can refer to the same entity or to distinct entities with equal-looking fields. |
| 29 Copying a class | Call copy() when a new top-level class identity is needed. |
| 30 Explicit constructors | A class can replace implicit field construction with a same-named constructor. |
| 31 Computed properties | A computed property presents accessor behavior with field-like syntax. |
| 32 Fluent methods | A method may return this so the caller can continue operating on the same object. |
Handle absence and match states
| Lesson | New feature |
|---|---|
| 33 Nullable values | A ? on a type permits null; the type without ? does not. |
| 34 Flow narrowing | A null check can prove a nullable value non-null inside a branch. |
| 35 Safe access | ?. reads a member only when its receiver exists. |
| 36 Null fallback | ?? uses its right operand only when the left operand is null. |
| 37 Plain enums | An enum lists a finite set of named alternatives. |
| 38 Data enums | Enum alternatives may carry differently typed data. |
| 39 Switch results | switch can produce a result while extracting an enum variant's payload. |
| 40 Exhaustive matching | A switch over a closed enum must account for every variant. |
| 41 Nested patterns | A pattern may match a variant inside another variant's payload. |
Compose abstractions
| Lesson | New feature |
|---|---|
| 42 Interface declarations | Specify a callable contract. |
| 43 Implementing an interface | Provide the required behavior. |
| 44 Default interface methods | Share behavior in the contract. |
| 45 Class inheritance | Extend a class and initialize its base. |
| 46 Overriding methods | Dispatch to a subclass implementation. |
| 47 Generic types | Parameterize a data type. |
| 48 Generic functions | Parameterize a calculation. |
| 49 Generic inference | Infer type arguments from call values. |
| 50 Matching generic types | Distinguish generic instantiations at runtime. |
| 51 Function overloads | Select a signature by argument type. |
Functions as values
| Lesson | New feature |
|---|---|
| 52 Function values | Store and pass callable values. |
| 53 Lambdas | Create a function value at its use site. |
| 54 Capturing values | Keep access to an enclosing value. |
| 55 Bound method references | Bind a callable to an object. |
| 56 Extension functions | Call a static function through receiver syntax. |
| 57 Trailing callbacks | Supply a final callback as a block. |
| 58 Named callback parameters | Name a callback's supplied value. |
| 59 Chaining block calls | Compose functions with trailing blocks. |
Build a project
| Lesson | New feature |
|---|---|
| 60 Imports | Use a public declaration from another package. |
| 61 Modules | Describe a module's name, version, and exports. |
| 62 Packages | Give source files structured names. |
| 63 Visibility | Separate public API from file-private details. |
| 64 Local dependencies | Consume a packaged library through the module graph. |
| 65 Tests | Declare and run a test. |
| 66 Exception handling | Catch exceptional control flow. |
| 67 Cleanup with finally | Run cleanup on every exit. |
Describe declarations
| Lesson | New feature |
|---|---|
| 68 Type declaration references | Read type metadata through a checked declaration. |
| 69 Field declaration references | Read and write a field through its descriptor. |
| 70 Function declaration references | Use a checked callable declaration reference. |
| 71 Annotation targets | Restrict where an annotation may appear. |
| 72 Annotation retention | Choose how long annotation data remains available. |
| 73 Runtime annotation metadata | Read a runtime-retained annotation. |
| 74 Function interception | Wrap a function call with around. |
| 75 Interceptor entry and exit | Observe before, body, and after order. |
| 76 Documenting declarations for agents | Expose checked intent through @Document and query. |
Observe and build
| Lesson | New feature |
|---|---|
| 77 Lexical references | Borrow a writable local location. |
| 78 Field handles | Bind a field descriptor to an object. |
| 79 Field subscriptions | Watch assignments and close a subscription. |
| 80 Collection change notifications | Watch collection mutations through a field. |
| 81 Resource ownership | Register and release owned subscriptions. |
| 82 Result builders | Accumulate expressions into a result. |
| 83 Control flow in result builders | Accumulate selected branches and loop iterations. |
Use libraries
| Lesson | New feature |
|---|---|
| 84 JSON value roundtrip | Encode and decode a checked value. |
| 85 Writing and reading a file | Claim a new file and read it back. |
| 86 Typed file failures | Handle a missing file by failure category. |
| 87 A packaged library | Consume an external library through a direct dependency. |
For a complete GUI Todo and Web guestbook, use the generated norm hello programs with the development toolchain.
The Language Reference defines precise rules; Status describes released capabilities.
Start with Program entry.