That reminds me of the time I had to debug this old BASIC game that used hundreds of expressions like
y = 4 - (x > 3) * 2
to achieve
$y = $x > 3 ? 6 : 4;
Some assignments even had more than one such conditional per line. It was hell.
(True was -1)
In reply to Re^2: comparison with bitwise operators (horror)
by ikegami
in thread comparison with bitwise operators
by alextor
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |