undar-lang/test/string.ul

16 lines
253 B
Plaintext
Executable File

str hello = "hello World!";
print(hello.length as str);
hello[0] = hello[0] - ' ';
print(hello);
halt;
function print(str string) {
nat i = 0;
while (i < string.length) {
write = string[i];
i = i + 1;
}
write = '\n';
}