2 条评论

  • @ 2024-10-4 12:20:52

    tgxr887 常1587t87c78915 79X 757 7 85G83RG54UY IOW5 GC G58 558

    • @ 2024-10-3 12:17:58
      #include<bits/stdc++.h>
      using namespace std;
      int q[32770];
      int main()
      {
      	freopen("light.in","r",stdin);
      	freopen("light.out","w",stdout);
      	int a,s;
      	cin>>a>>s;
      	bool o=0;
      	for(int j=2;j<=s;j++){
      	for(int i=2;i<=a;i++){
      		if(i%j==0){
      			if(q[i]==0){
      				q[i]=1;
      			}
      			else{
      				q[i]=0;
      			}
      		}
      	}
      }
      	for(int i=2;i<=a;i++){
      		if(q[i]!=0){
      			cout<<i<<" ";
      			o++;
      		}
      	}
      	if(o==0){
      		cout<<"NO";
      	}
      	return 0;
      }
      
      • 1