60分求救 3AC 2WA
查看原帖
60分求救 3AC 2WA
1091120
yyc1231楼主2024/4/4 09:26
#include<bits/stdc++.h>
using namespace std;

int main(){
	int s,x;
	double a,v;
	cin>>s>>x;
	while(a>s-x){
        a+=v;
		v*=0.98;
	}
	if(a+v<=s+x){
		cout<<"n";
	}else{
		cout<<"y";
	} 
	return 0;
}

2024/4/4 09:26
加载中...