next up previous contents
Next: Features of MLton Up: Getting started Previous: Installation   Contents

Hello, World!

Create a file called hello-world.sml with the following contents.

print "Hello, world!;\n"
Now, create an executable called hello-world with the following command.
mlton hello-world.sml
You can now run this executable to verify that it works. There are several other small examples in examples. In particular, there are examples that demonstrate world save and restore, callcc, object size primitive, threads, profiling, and the FFI.