Skip to content

Hello World

Create a file called hello.chuks:

println("Hello, World!")

Run it:

Terminal window
chuks run hello.chuks

Output:

Hello, World!

That’s it! Chuks programs run with or without a main() function or entry point class. Top-level statements execute sequentially, just like a scripting language.

Let’s try something with variables and a function:

greet.chuks
function greet(name: string): string {
return `Hello, ${name}!`;
}
const message = greet("Chuks")
println(message)
Terminal window
chuks run greet.chuks
Hello, Chuks!

You can also compile to a native executable using chuks build command:

Terminal window
chuks build hello.chuks
./hello.chuks.bin

This produces a standalone binary you can distribute without requiring the Chuks runtime.

Ready to build something real? Create your first project.