标签:
Description
Input
Output
Sample Input
Sample Output
#include<cstdio> using namespace std; int main() { int n; while(~scanf("%d",&n)!=EOF) { int num=0; int ans=1; while(n) { if(n%2==1)num++; n/=2; } for(int i=1;i<=num;i++)ans*=2; printf("%d\n",ans); } }
HDU 4349 Xiao Ming's Hope lucas定理
标签:
原文地址:http://www.cnblogs.com/zxhl/p/4746156.html