Evaluate expression/s under some condition
if[test;e1;e2;e3;…;en]
Control construct. Where
test is an expression that evaluates to an atom of integral typee1, e2, … en are expressionsunless test evaluates to zero, the expressions e1 to en are evaluated, in
order.
The result of if is always the generic null.
q)a:100
q)r:""
q)if[a>10;a:20;r:"true"]
q)a
20
q)r
"true"