http://acm.hdu.edu.cn/showproblem.php?pid=1056
#include<iostream>
#include<cstdio>
#include<cstring>
#include<cmath>
#include<algorithm>
#include<bitset>
using namespace std;
int main()
{
double sum , c ;
int ans ;
while( ~scanf( "%lf" , &c ) )
{
ans = 2 ;
sum = 0 ;
if( c == 0 )
break ;
while( c > sum )
{
sum += 1.0 / ans ;
ans++ ;
}
printf( "%d card(s)\n" , ans - 2 ) ;
}
return 0 ;
}