BrainTeasers
Showing posts with label
power of 2
.
Show all posts
Showing posts with label
power of 2
.
Show all posts
Wednesday, September 23, 2009
power of 2
how will you find whether a number is a power of 2 or not in single step.
click here for answer
if(n>0 && (n & (n-1))) {cout<<"power of 2";}
Older Posts
Home
Subscribe to:
Posts (Atom)