Boolean values in Jaf are represented as numbers: 1 for true, 0 for false.
print(5 > 3) # 1 (true) print(5 == 3) # 0 (false) print(5 != 3) # 1 (true)
print(1 && 1) # 1 print(1 && 0) # 0 print(1 || 0) # 1 print(0 || 0) # 0
debug = 1
if (debug) {
print("Debug mode on")
}
# Output: Debug mode on
debug = 0
if (debug) {
print("This won't print")
}
In conditions, any non-zero value is considered true:
if (42) { print("True!") } # Prints
if (-5) { print("True!") } # Prints
if (0) { print("False!") } # Doesn't print
© 2026 elliktronic · Jaf Language