mirror of
https://github.com/Kiritow/OJ-Problems-Source.git
synced 2024-03-22 13:11:29 +08:00
25 lines
393 B
C++
25 lines
393 B
C++
|
#include"cstdlib"
|
||
|
#include"cstdio"
|
||
|
#include"cstring"
|
||
|
#include"cmath"
|
||
|
#include"stack"
|
||
|
#include"algorithm"
|
||
|
#include"iostream"
|
||
|
#define ll __int64
|
||
|
using namespace std;
|
||
|
int main()
|
||
|
{
|
||
|
int n;
|
||
|
while(cin>>n)
|
||
|
{
|
||
|
int cnt=0;
|
||
|
while(n)
|
||
|
{
|
||
|
if(n%2==1) cnt++;
|
||
|
n/=2;
|
||
|
}
|
||
|
printf("%d\n",1<<cnt);
|
||
|
}
|
||
|
return 0;
|
||
|
}
|