An interpreter for kera language, my first attempt to create an interpreter.
Using cargo
cargo run
It can now display correct expression precedence.
TODO:
- Lexer
- Parser
- Statements
- Expressions
- Evaluation
- REPL
- Add more data types
misal lima = 5;
misal sepuluh = 10;
misal tambah = fungsi(x, y) {
kembalikan x + y;
}
misal larik = [1, 2, 3, tambah(lima, sepuluh)];
misal hasil = terakhir(larik);
jika hasil > 10 {
kembalikan benar;
} lainnya {
kembalikan salah;
}
Output: benar