q/examples/hello/hello.q

17 lines
No EOL
155 B
Text

main() {
x := f(1) + f(2) + f(3)
if x != f(8) || x != 9 || x == 6 {
exit(42)
}
exit(0)
}
exit(code) {
syscall(60, code)
}
f(x) {
return x + 1
}