80分,求调
查看原帖
80分,求调
1371636
includeC_xz楼主2025/7/29 08:09
#include<bits/stdc++.h>
using namespace std;
string pj;
bool pd=false;
int a,b,c;
int main(){
	cin >>a>>b>>c;
	for(int i=1;i<=999/c+c;i++){
		if(i*c<=999){
			pj=to_string(i)+to_string(i*b)+to_string(i*c);
			sort(pj.begin(), pj.end());
			if(pj=="123456789"){
				pd=true;
				cout <<i<<" "<<i*b<<" "<<i*c<<endl;
			}
		}
	}
	if(pd==false){
		cout <<"No!!!";
	}
	return 0;
}

错了第五个测试点错误

2025/7/29 08:09
加载中...