View on GitHub


A Customizable Stack-Oriented Imperative Programming language

About | Examples | Documentation | Downloads

Download this project as a .zip file Download this project as a tar.gz file


MontiLang is a Stack-Oriented imperative programming language developed in python. It is highly customisable and contains many features found in higher level and Object Oriented languages.

Current State

Some of the features that are currently implemented are as follows:

The following will be coming soon:


The simplest way to use MontiLang is to download the binaries from the Releases page. Alternatively, you can download and build from the source code with the instructions below.

The easiest way to compile and use Monti is through the python package ‘Pyinstaller’. Install Pyinstaller from PyPi and download the MontiLang source code.

On windows:

install mysysgit, or download source files directly.

python -m pip install pyinstaller
git clone
cd MontiLang/src
pyinstaller icon=../icon.ico -n monti
SETX /M path "%path%;C:\[path_to_directory]\MontiLang\src\dist\monti"

On Linux:

use pip, or the built-in package manager for your distro to install pyinstaller. If this does not work, install from the Pyinstaller releases and run, or run straight from the source code from

git clone
cd /MontiLang/src
pyinstaller icon=../icon.ico -n monti


To interpret a Monti file, use

path/to/monti/executable [file] <optional flags>

If no file is specified, Monti will launch into an interactive REPL

Including the the -c flag will cause the program to not run, but will preprocess and print the source code as it is read by the interpreter


Example program that takes an input as a number, and prints that far into the Fibonacci sequence.

/# Test Fibonacci program #/
|Enter length of sequence: | INPUT NIP VAR loop .

0 VAR a .
1 VAR b .
FOR loop
    a b + VAR c .
    a PRINT .
    b VAR a .
    c VAR b .

FizzBuzz: Program that loops through numbers 1-100, prints ‘fizz’ if it is a multiple of 3, ‘buzz’ if a multiple of 5, and ‘fizzbuzz’ if both. &DEFINE LOOP 100& 1 VAR i .

    || VAR ln .
    i 5 % 0 == 
    IF : .
        ln |Buzz| + VAR ln .
    i 3 % 0 ==
    IF : .
        ln |Fizz| + VAR ln .
    ln || ==
    IF : .
        i PRINT .
    ln || !=
    IF : .
        ln PRINT .
i 1 + VAR i .

See the file in /examples for a more detailed explanation of language features.

Help contribute to MontiLang, add examples on rosettacode at