提交时间:2025-07-09 16:30:48
运行 ID: 330318
#include<bits/stdc++.h> using namespace std; int sb(int x){ int a=0,b=0,c=0; a=x/100%10; b=x/10%10; c=x/1%10; if(a+b==1){ return 0; } for(int i=2;i<=9;i++){ if(a+b==i && (a+b)%i==0){ return 0; } } if(b>a+c){ return x; } else{ return 0; } } int main(){ for(int i=100;i<=999;i++){ if(sb(i)){ cout<<i<<endl; } } return 0; }