Skip to content

wyx0-xyz/flush

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

flush-lang

flush-lang is an interpreted programming language written in Rust.

stars forks

Installation

You need git (or you can download the zip project) and cargo (for the build).

git clone https://github.com/flush-lang/flush
cd flush
cargo test
cargo install --path .

Version

Show the current flush's version by using: flush --version or flush -V.

Usage

Run a file with: flush <path/to/file>.

Examples

You can find all examples here.

def main() {
    putStrLn("Hello, World!")
}
def fac(n) {
    if (n <= 1) {
        return 1
    }

    return n * fac(n - 1)
}
def fizz(n) {
    if (0 == n % 15) {
        putStrLn("FizzBuzz")
    } else {
        if (0 == n % 5) {
            putStrLn("Buzz")
        }
        
        if (0 == n % 3) {
            putStrLn("Fizz")
        } else {
            printLn(n)
        }
    }
}

License

Distributed under the MIT License. See license for more information.

About

Programming language written in Rust.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages