mirror of
https://github.com/Noratrieb/Hunterlang.git
synced 2026-01-14 20:45:00 +01:00
Update README.md
This commit is contained in:
parent
d7c9aeb127
commit
4fa881f525
1 changed files with 48 additions and 0 deletions
48
README.md
48
README.md
|
|
@ -1 +1,49 @@
|
|||
# Hunterlang
|
||||
A hunter x hunter themed interpreted esoteric programming language.
|
||||
A the first version of the lexer is done, the parser is still in work.
|
||||
Some example code:
|
||||
```
|
||||
#Add two numbers
|
||||
Leorio does say "Number 1"
|
||||
killua0 hunts Leorio does listen
|
||||
Leorio does say "Number 2"
|
||||
killua2 hunts Leorio does listen
|
||||
killua3 hunts killua0 + killua1
|
||||
Leorio does say killua3
|
||||
```
|
||||
|
||||
|
||||
```
|
||||
#Output the smaller number or both if they are equal
|
||||
Leorio does say "Number 1"
|
||||
killua0 hunts Leorio does listen
|
||||
Leorio does say "Number 2"
|
||||
killua2 hunts Leorio does listen
|
||||
Gon wants killua0 > killua1 {
|
||||
Leorio does say killua1
|
||||
} wants killua1 > killua0 {
|
||||
Leorio does say killua0
|
||||
} got {
|
||||
Leorio does say killua0 + " " + killua1
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
```
|
||||
#Read in 2 numbers using a function and output their sum with a function
|
||||
Read2 Zoldyck gets 0 does {
|
||||
Leorio does say "Number 1"
|
||||
killua0 hunts Leorio does listen
|
||||
Leorio does say "Number 2"
|
||||
killua2 hunts Leorio does listen
|
||||
}
|
||||
|
||||
Add Zoldyck gets 2 gives {
|
||||
illumi0 + illumi1
|
||||
}
|
||||
|
||||
Read2
|
||||
Leorio does say add killua0 killua1
|
||||
```
|
||||
|
||||
sadly, Github syntax highlighting is not available yet
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue