Demo Programs

In this chapter we will see simple demo programs

  • Language Shell
  • Main Menu

Language Shell

We can create simple interactive programming environment using the next program

while true
        see nl + "code:> "
        give cCode
        try
                eval(cCode)
        catch
                see cCatchError
        done
end

Output:

code:> see "hello world"
hello world
code:> for x = 1 to 10 see x + nl next
1
2
3
4
5
6
7
8
9
10

code:> func test see "Hello from test" + nl

code:> test()
Hello from test

code:> bye