diff --git a/examples/hello_world.dn b/examples/hello_world.dn index 64318a1..57364f9 100755 --- a/examples/hello_world.dn +++ b/examples/hello_world.dn @@ -1,7 +1,20 @@ -def Main : { - printf["hello world"]; - printf["wtf2"]; - printf["wtf1"]; +// another function +def AnotherFunction : { + printf["Hello from another function!"]; }; + +// every program needs a main :) +def Main : { + // define variables + a = 10; + b = 20; + + // print statements + printf["a + b: "]; + printf[{ int } a + b]; + + // calling functions + call AnotherFunction; +}; call Main;