You need Agda version 2.5.2 or 2.5.3. You can get Agda 2.5.3 from Hackage with "cabal install Agda". You will also need the agda-prelude library from https://github.com/UlfNorell/agda-prelude The branch compat-2.5.3 works with Agda 2.5.3, so from the command line you can say git clone https://github.com/UlfNorell/agda-prelude --branch compat-2.5.3 The next step is to tell Agda where to find the library. This is accomplished by creating a file ~/.agda/libraries [1] (or adding to it if you already have one) containing the full path to the agda-prelude.agda-lib file in the repository you just checked out. To compile the code, open Main.agda in Emacs and hit C-c C-x C-c, or from the command-line: agda -c Main.agda [1] On Windows systems it should be C:\Users\USERNAME\AppData\Roaming\agda\libraries.