P7909CSP—j 90分代码
  • 板块灌水区
  • 楼主a6b6c6d6
  • 当前回复4
  • 已保存回复4
  • 发布时间2024/9/23 22:51
  • 上次更新2024/9/24 14:04:48
查看原帖
P7909CSP—j 90分代码
1354472
a6b6c6d6楼主2024/9/23 22:51
#include<bits/stdc++.h>
using namespace std;
int n,l,r,s=INT_MIN;
int main(){
	cin>>n>>l>>r;
	for(int i=l;i<=r;i++){
		if(i%n==n-1){
			cout<<n-1;
			return 0;
		}
		if(i%n>s)s=i%n;
	}
	cout<<s;
	return 0;
}
2024/9/23 22:51
加载中...