Okto is an interpreted programming language written in C++. It's a strongly typed language which tells you exactly where you messed up if there's an error. Both a REPL and file input are supported.
## Why is Okto?
No reason.
Maybe one day the NodeJS community will find it and obsess over it in it's unoptimisedness. But that remains to be seen.
Run `./okto` to run, and test with `./okto example.okto` (assuming you did clone the repository)
### MacOS
First, install Xcode and accept the agreement.
Then, clone the repository CD into it and run:
```bash
g++ src/main.cpp -o okto -std=c++17
```
If needed, statically link with `-static`.
Run `./okto` to run, and test with `./okto example.okto` (assuming you did clone the repository)
### Windows
There are three ways to compile for Windows: through Linux (I personally recommend, can be done through WSL), through MSYS2 or Cygwin, or through Windows.
#### Through Linux
Install your distro's mingw GCC package. On Arch Linux, it's `mingw-w64-gcc`. Compile with:
`type`: Check the type of something. If it doesn't have a type, it's unknown. Usage: `type (function, variable, string, decimal, integer, incrementor, modifier, operator, comparitor, equals)` Example: `type 432`
`in`: Take input from the console. For now, this doesn't do much, but this will change soon. Usage: `in (optional: string)` Example: `in "What's your name? "`
`exit`: Exit the program. Usage: `exit (optional: integer)`
Okto is strongly typed, which means we need to learn about all the different types in the language! At present there are three types in Okto: strings, integers and decimals. Defining variables uses a C/C++ like syntax.
#### Strings
Strings are a bunch of letters enclosed in double quotes, like `"this"`.
Define a string in Okto with `str myString = "Hello World!"`
#### Integers
Integers are whole numbers, like `7`.
Define an integer in Okto with `int myInteger = 7`
Use variables in your code like `$variable`, but replace variable with your actual variable's name. Make sure to use correct types in places! Incorporate a variable inside a string with `"${variable}"`
Add stuff together in number variables with `myVariable = $myOtherVariable + 7`. You can also subtract, multiply and divide with -, * and / respectively. For now you can't math outside of variables as it's still a prototype feature.