阳光WA大男孩
查看原帖
阳光WA大男孩
945742
hexuchen楼主2023/4/30 11:40

求助!最后两个测试点都错了 QWQ 看了别人的感觉和我也差不多啊?

#include <iostream>
using namespace std;
int main(){
	int n,x,y,a;
	cin>>n>>x>>y;
	if(x!=0){
			if(y%x==0)
			cout<<n-(y/x);
		else{
			a=y/x+1;
			if(a>=n)
				cout<<0;
		}
	}
	else
		cout<<0;
	return 0;
}
2023/4/30 11:40
加载中...