@[Kvj123456](/user/569914) 你这个循环都进不去啊)))
应该是
```
while(1){
if (i>=sum){....
```
这样子,还有一些细节
by Luban @ 2021-10-06 19:50:27
```cpp
#include<bits/stdc++.h>
using namespace std;
int main(){
int a=0(修改),b=1;
double num=0,i=2.0,sum;
cin>>sum;
while(1){
if(num>=sum){
cout<<a<<endl;
return 0;
}
else{
num+=i;
i*=0.98;
a++;
}
}
return 0;
}
```
by Luban @ 2021-10-06 19:52:38
@[Kvj123456](/user/569914) 大体上就这样了吧qwq
我今天模拟赛炸了心情很差,让我缓缓/kk
by Luban @ 2021-10-06 19:53:22
不知不觉我学信奥两年了还是这么菜这么弱
by Kvj123456 @ 2023-10-17 09:15:11