determining if a number is a power of 2