https://github.com/inunix3/monolog
Simple interpreted C-like programming language.
https://github.com/inunix3/monolog
c c-like c11 homemade-programming-language interpreted-programming-language just-for-fun programming-language
Last synced: 4 months ago
JSON representation
Simple interpreted C-like programming language.
- Host: GitHub
- URL: https://github.com/inunix3/monolog
- Owner: inunix3
- License: mit
- Created: 2025-03-10T04:20:41.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2025-06-08T18:22:42.000Z (4 months ago)
- Last Synced: 2025-06-08T19:27:30.197Z (4 months ago)
- Topics: c, c-like, c11, homemade-programming-language, interpreted-programming-language, just-for-fun, programming-language
- Language: C
- Homepage:
- Size: 3.49 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# monolog
A simple interpreted C-like programming language.
This was a school project, so the language is toyish and the interpreter is pretty simple.
Anyway, created just for fun.
```c
println("Hello, World!");void fizzbuzz(int n) {
if (n <= 0) {
return;
}for (int i = 1; i <= 100; ++i) {
print($i + "... ");if (i % 15 == 0) {
println("fizz buzz");
} else if (i % 3 == 0) {
println("fizz");
} else if (i % 5 == 0) {
println("buzz");
} else {
println("");
}
}
}fizzbuzz(100);
```## Features
- Imperative
- Infix notation (`2 + 3 / 0`)
- Arithmetic (`+, -, *, /, %`)
- Logic (`!, ==, !=, <, >, <=, >=, &&, ||`)
- Basic branching statements (`if, else`)
- Loops (`while, for, break, continue`)
- Block statements
- Functions
- Builtin types:
- 64-bit signed integers (`int`)
- Mutable, resizable strings (`string`)
- Option types (`T?`)
- Arrays (`[T]`)
- REPL## Examples and documentation
Example programs are located in `examples/`.
Reference for the language you can find in `docs/`.
## Building
See documentation in `docs/`.
## License
Monolog is licensed under the [MIT License](LICENSE.md).