Wheel IDE

Online demo »

String, add

String add example

This example demonstrates how to declare a string and add values to it.

Code

#project "String add example"

#include "lib/modules/standard.whl"

proc main()
    clearConsole()

    ; Print "One" in the console:
    string s
    s = "One"
    printS(s)

    ; Print "One two" in the console:
    s = s + " two"
    printS(s)

    ; Print "One two three" in the console:
    s = s + " three"
    printS(s)
end