Skip to content

OCaml introductory bootcamp by Jane Street (exercise solutions by me), 2025

Notifications You must be signed in to change notification settings

SlaveToJavascript/intro-to-ocaml

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Exercises to get started with OCaml syntax. We will go through these together as a group, so don't worry if you run into problems to start!

Getting Started

First, let's start by compiling the existing code. Once you're in the intro-to-ocaml directory, you can run the following to compile your code:

$ dune build

This command will make dune build the default targets for this directory

You can also run dune in polling mode, which will watch your filesystem for any changes and rebuild when necessary. To do this, run the following (probably in its own terminal):

$ dune build -w

OCaml code can be autoformatted using ocamlformat. To format your code, run

$ dune fmt

If you're using VSCode, you can configure your editor to automatically save and format your code periodically. Otherwise, you might want to run the above command periodically to manually format your code.

Each exercise has its own tests. To run the tests for exercise number N, run

$ dune runtest tests/exerciseN

About

OCaml introductory bootcamp by Jane Street (exercise solutions by me), 2025

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published