Open oscbyspro opened 1 month ago
The following models can and/or should implement isPowerOf2.
isPowerOf2
I want at least Count/isPowerOf2 for documentation purposes.
Count/isPowerOf2
Also, this expression is faster than bit-counting (for small systems integers):
(x > 0) && (x & (x &- 1) == 0)
The following models can and/or should implement
isPowerOf2
.I want at least
Count/isPowerOf2
for documentation purposes.