题解
2025-04-15 18:33:43
发布于:广东
6阅读
0回复
0点赞
#include<bits/stdc++.h>
using namespace std;
int a;
int main(){
    cin>>a;
    if(a%3==0&&a%5==0&&a%7==0)cout<<"3 5 7";
    else if(a%3==0&&a%5==0)cout<<"3 5";
    else if(a%3==0&&a%7==0)cout<<"3 7";
    else if(a%7==0&&a%5==0)cout<<"5 7";
    else if(a%7==0)cout<<"7";
    else if(a%5==0)cout<<"5";
    else if(a%3==0)cout<<"3";
    else cout<<"no";
    return 0;
}
这里空空如也







有帮助,赞一个