For the first puzzle, code that determines if a value has one bit high, without any if/while/for, here's what I got:
!(x & (x-1)) && x
Was there a "best" solution somewhere? I couldnt get the code window to work.
!(x & (x-1)) && x
Was there a "best" solution somewhere? I couldnt get the code window to work.