Skip to content

Hello, World!

Every Zolo program is a sequence of statements executed top to bottom. print writes a line to standard output:

A first program: a const, a function with an annotated return type, and the pipe operator |> feeding a value into a call.

00-hello.zolo
Playground
const test1 = 2

/// Multiplies two integers and returns the result.
fn mul(a: int, b: int) -> int {
  return a * b
}

let result = test1 |> mul(2)
print("Hello from Zolo!")
print("2 * 2 = {result}")

See also

enespt-br