标签:scan 分享 can style line span lin isp close
1 #include<stdio.h> 2 int main() 3 { 4 int d,n,i,j; 5 scanf("%d",&d); 6 for (i=1;i<=d;i++) 7 { 8 scanf("%d",&n); 9 int s=0,v=0; 10 for (j=n;j;j=j/2,s++) 11 { 12 13 if (j%2==1) 14 { 15 if (v==0) 16 { 17 printf("%d",s); 18 v=1; 19 } 20 else 21 printf(" %d",s); 22 } 23 } 24 printf("\n"); 25 } 26 }
ZOJ:1383
标签:scan 分享 can style line span lin isp close
原文地址:http://www.cnblogs.com/domen0814/p/6806494.html