Update README.md

master win-64
xerox 5 years ago
parent ec74084497
commit ab0610854a

@ -12,7 +12,7 @@ Supported operating systems and downloads:
# Hello World. # Hello World.
Hello world in Deon. Hello world in Deon.
``` ```c
def main: def main:
{ {
print["hello world"]; print["hello world"];
@ -24,7 +24,7 @@ call main;
* Variables support "type juggling" where types are assumed at runtime. * Variables support "type juggling" where types are assumed at runtime.
* Variables can be assigned to each other even if they are different types. * Variables can be assigned to each other even if they are different types.
``` ```c
/* main function */ /* main function */
def main: def main:
{ {
@ -46,7 +46,7 @@ call main;
* As ov v0.9.5 expressions are only supported for int types, I need to recode the entire expression parsing system * As ov v0.9.5 expressions are only supported for int types, I need to recode the entire expression parsing system
to support up to doubles. to support up to doubles.
``` ```c
def main: def main:
{ {
var = 10 + (5 * 2 / (11 % 2)); var = 10 + (5 * 2 / (11 % 2));
@ -59,7 +59,7 @@ call main;
# Scope # Scope
* As of v0.9.5 there is not scope inside of this programming language. * As of v0.9.5 there is not scope inside of this programming language.
``` ```c
/* changes var from 10 to 100 */ /* changes var from 10 to 100 */
def another_function: def another_function:
{ {
@ -85,7 +85,7 @@ call main;
### If statements ### If statements
* As stated above, if statement conditions must be a variable. * As stated above, if statement conditions must be a variable.
``` ```c
def main: def main:
{ {
var = 1; var = 1;
@ -104,7 +104,7 @@ call main;
### While loop ### While loop
``` ```c
def main: def main:
{ {
var = 1; var = 1;
@ -121,7 +121,7 @@ call main;
# Functions # Functions
* Functions can be defined as variables (lambda) or defined normally. * Functions can be defined as variables (lambda) or defined normally.
``` ```c
def my_function: def my_function:
{ {
some_function = { some_function = {
@ -136,13 +136,15 @@ call my_function;
* As of v0.9.5 everything in this programming language can be redefined. That means everything, including the function that * As of v0.9.5 everything in this programming language can be redefined. That means everything, including the function that
is currently being executed. is currently being executed.
``` ```c
def main: def main:
{ {
main = { main = {
print["i just redefined main"]; print["i just redefined main"];
}; };
}; };
call main; call main;
call main; call main;
``` ```

Loading…
Cancel
Save