3 ms·
Interestingly, in logic programming languages if/else sometimes turns into arithmetic, so (slightly simplifying) 'if x then y else z' becomes 'xy + (1-x)z', or
by CJefferson 6y ago
Interestingly, in logic programming languages if/else sometimes turns into arithmetic, so (slightly simplifying)
'if x then y else z' becomes 'xy + (1-x)z', or 'x*(y-z)+z'