#include <iostream>
using namespace std;
int main()
{
int a = 128;
int b = a-1;
if(a && !(a & b))
{
cout<<"Number is power of 2"<<endl;
}
else {
cout<<"Number is not power of 2"<<endl;
}
}
top of page
All of us do not have equal talent. But, all of us have an equal opportunity to develop our talents.
-A.P.J Abdul Kalam
bottom of page
Comments