题解(A67.守望者的逃离)
2024-09-06 14:11:28
发布于:四川
1阅读
0回复
0点赞
#include<bits/stdc++.h>
#define int long long
using namespace std;
int m,s,t;
signed main(){
cin>>m>>s>>t;
int flyS=0,runS=0;
for(int i=1;i<=t;i++){
runS+=17;
if(m>=10)flyS+=60,m-=10;
else m+=4;
if(flyS>runS)runS=flyS;
if(flyS>s||runS>s){
cout<<"Yes"<<endl<<i;
return 0;
}
}cout<<"No"<<endl<<max(runS,flyS);
return 0;
}
这里空空如也
有帮助,赞一个