Possible Duplicate:
How to check if a number is a power of 2
How could I write a method that would return true if passed in the value 2, 4, 8, 32, 64, and so on?
Possible Duplicate:
How to check if a number is a power of 2
How could I write a method that would return true if passed in the value 2, 4, 8, 32, 64, and so on?