求大佬看下为啥不行啊

P1423 小玉在游泳

希望更丰富的展现?使用Markdown
by nofall @ 2018-11-06 22:48:39


``` #include<bits/stdc++.h> using namespace std; int main(){ double swim=2,G=0,x; cin>>x; for(int i=1;;i++) { G=G+swim; swim=swim*0.98; if(G>=x){cout<<i;break;} } return 0; } ```
by LinAPro @ 2018-11-06 22:56:17


|