Wednesday, December 24, 2014

Monkey getting started - Printing Global variables Example code


I am following the youtube tutorials for beginners for monkey and then I made this.

Code below ( Copy and paste it into notepad and then copy paste it into the mokey editor and run it.

This is the outputted result. As you can see the floating value is not what you might of expected,

100
1.1000000238418579
Hello


Global val1:Int = 100
Global val2:Float = 1.1
Global txt1:String = "Hello"

Function Main:Int()
    Print(val1)
    Print(val2)
    Print(txt1)
    Return 0
End Function

No comments:

Post a Comment