hdu-1056 HangOver
#include<stdio.h>
int main()
{
double n,temp,t;
while(~scanf("%lf",&n),n!=0.00)
{
temp=0;
t=2.0;
while(n>temp)
{
temp+=1/t;
t++;
}
printf("%.lf card(s)\n",t-2);
}
return 0;
}水果。。。。。。。。。。虽然试了好多次。。。。

浙公网安备 33010602011771号