以下判断奇数的AC代码在输入999999时输出 1.04858e+006 20 建议加强数据到评测中 正确输出: 1048576 20
for(int i=0;i<=20;i++){ if(pow(2,i)>=n){ cout<<pow(2,i)<<" "<<i; break; } }