https://github.com/rexionmars/snake-lang
SNAKE is a Concatenative Stack-Oriented Programming Language
https://github.com/rexionmars/snake-lang
assembly bytecode compiled-language concatenative-programming-language linux native programming-language stack-based x86-64
Last synced: 6 months ago
JSON representation
SNAKE is a Concatenative Stack-Oriented Programming Language
- Host: GitHub
- URL: https://github.com/rexionmars/snake-lang
- Owner: rexionmars
- License: mit
- Created: 2023-04-19T19:29:39.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2023-06-30T19:43:54.000Z (almost 3 years ago)
- Last Synced: 2025-06-09T04:08:14.248Z (10 months ago)
- Topics: assembly, bytecode, compiled-language, concatenative-programming-language, linux, native, programming-language, stack-based, x86-64
- Language: Python
- Homepage:
- Size: 742 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
[](https://opensource.org/licenses/MIT)




SNAKE is a Concatenative Stack-Oriented Programming Language.
This will be updated soon
## Main characteristics
- [x] Compiled
- [x] Native
- [x] Stack-based
## Quick Start
```sh
$ git clone https://github.com/rexionmars/snake.git
```
```sh
$ cd snake
```
## Folder Structure
```lua
docs/refs/
|
+-- Documentations and references
container/
|
+-- Standard scripts from translate code (temporary)
snake.py
|
+-- This file is the principal and contain base functions
```
## SNAKE usage
Sanake has two modes of operation, the first mode to Simulate the program, and the second mode to Compile the program.
SNAKE without parameters returns the help menu
```sh
$ ./snake.py
```
simulate program
```sh
$ ./snake.py run
```
or compile the program x86_64 Linux
```sh
$ ./snake.py compile
```
this will generate an x86_64 Linux executable, in the tests folder
```sh
$ cd tests && ./output
```
## Your first Hello World in SNAKE (in initial state)
A simple example using PUSH, PLUS, MINUS, DUMP
Use your favorite editor, i love neovim
```sh
$ nvim sun.snake
```
Example 1: sun two numbers
```sh
49 99 + .
```
Example 2: subtrac two numbers
```sh
13 9 - .
```
Example 3: if condition
```sh
17 1 + 18 = if
700 .
end
```
## Contributors
