0Pricing
Mojo Academy · Lesson

Running with mojo run

Execute a program from the command line.

From File to Running Program

You have a saved hello.mojo file. To see it work, you launch it from your terminal with the mojo command. 🖥️

The mojo run Command

The simplest way to execute a file is mojo run followed by the file name. Mojo compiles and runs it in one step.

mojo run hello.mojo

All lessons in this course

  1. Your First .mojo File
  2. The main Entry Point
  3. Running with mojo run
  4. Exploring in the Mojo REPL
← Back to Mojo Academy