AnthonyW @ 2018-11-18 20:00:57
int main(void) { float k,n,sum=0.0; scanf("%f",&k); for(n=1;n;n++) { sum=sum+1.0/n; if(sum>k) break; } printf("%.0f",n); return 0; }
by maorui_cow @ 2018-11-18 20:09:10
double
by maorui_cow @ 2018-11-18 20:09:19
hhh
by AnthonyW @ 2018-11-18 20:11:35
嗯嗯 我刚刚也想到改double了嘻嘻谢谢