0Pricing
Zig Academy · Lesson

Compile and Run in One Step

Use zig run to go from source to output.

From Source to Running

Normally you compile code into a binary, then run it. Zig folds both into a single friendly command: zig run. ⚡

The zig run Command

Point zig run at a source file and it compiles your program and immediately executes the result, all in one go.

zig run hello.zig

All lessons in this course

  1. Install Zig on Any Platform
  2. Your First main Function
  3. Printing with std.debug.print
  4. Compile and Run in One Step
← Back to Zig Academy