semeru/Code-Code-CloneDetection-POJ104 huggingface dataset:
int main()
{int a;
	scanf("%d",&a);
		if(a%3==0)
		{	printf("3");
			if(a%5==0)
			{	printf(" 5");
				if(a%7==0)
					printf(" 7");
				else
				return 0;
			}
			else
			{	if(a%7==0)
					printf(" 7");
				else
				return 0;
			}
		}
		else
		{	if(a%5==0)
			{	printf("5");
				if(a%7==0)
					printf(" 7");
				else
				return 0;
			}
			else
			{	if(a%7==0)
					printf("7");
				else
                    printf("n");
					return 0;
			}
		}
		

}
int main()
{
    int a=0;
	cin >>a;
	if (a%105==0)                                                        //????????3,5,7
		cout <<"3 5 7";
	else if (a%15==0 && a%7!=0)                                          //?????????3,5
		cout <<"3 5";
	else if (a%21==0 && a%5!=0)                                          //?????????3,7
		cout <<"3 7";
	else if (a%35==0 && a%3!=0)                                          //??????5,7
		cout <<"5 7";
	else if (a%3==0 && a%35!=0)                                          //???????????
		cout <<"3";
	else if (a%5==0 && a%21!=0)
		cout <<"5";
	else if (a%7==0 && a%15!=0)
		cout <<"7";
	else 
		cout <<"n";
	return 0;
}
int main()
{
	int a,b,c,d;
	cin>>d;
	a=d%3;
	b=d%5;
	c=d%7;
	if(a==0&&b==0&&c==0)
		cout<<3<<" "<<5<<" "<<7;
		else
		if(a==0&&b==0)
			cout<<3<<" "<<5;
		else
			if(a==0&&c==0)
				cout<<3<<" "<<7;
			else
				if(c==0&&b==0)
					cout<<5<<" "<<7;
				else
					if(a==0)
						cout<<3;
					else
						if(b==0)
							cout<<5;
						else
							if(c==0)
								cout<<7;
							else
								cout<<"n";
							
}
int main()
{
	int n,i,j=3,flag=0;
	scanf("%d",&n);
	for (i=3;i<=7;i+=2)
	{
		if (n%i==0&&flag==0) 
		{
			printf("%d",i);
			flag=1;
		}
		else if (n%i==0&&flag==1) printf(" %d",i);
		else j--;
	}
	if (j==0) printf ("n");
	return 0;
}
int main()
{
    int n,i,j,k,t;
    i=0;j=0;k=0;t=0;
    cin >>n;
    if (n%3==0) i=1;
    if (n%5==0) j=1;
    if (n%7==0) k=1;
    t=i+j+k;
    if (t==0) cout <<"n"<<endl;
    if (t==1)
    {
        if (i==1) cout <<3<<endl;
        if (j==1) cout <<5<<endl;
        if (k==1) cout <<7<<endl;
    }
    if (t==2)
    {
        if (i==0) cout <<"5 7"<<endl;
        if (j==0) cout <<"3 7"<<endl;
        if (k==0) cout <<"3 5"<<endl;
    }
    if (t==3) cout <<"3 5 7"<<endl;
    return 0;
}
int main()
{int n;
cin>>n;
if(n%3==0&&n%5==0&&n%7==0)
	cout<<"3 5 7";
else					//????????????
	{if(n%5==0&&n%7==0)
	cout<<"5 7";
	if(n%3==0&&n%5==0)
	cout<<"3 5";
	if(n%3==0&&n%7==0)
	cout<<"3 7";
	if((!(n%3==0&&n%5==0))&&(!(n%3==0&&n%7==0))&&(!(n%5==0&&n%7==0)))	//?????????????
		{if(n%3==0)
		cout<<'3';
		if(n%5==0)
		cout<<'5';
		if(n%7==0)
		cout<<'7';
		if(n%3!=0&&n%5!=0&&n%7!=0)		//???????????
		cout<<'n';
		}
	}
return 0;
}
void main()
{
	int a,b,c,space=0;
	scanf("%d",&a);
	b=a%3;c=a%5;
	if(a%3==0) 
	{
		printf("3"); 
		space=1;
	}
	if(a%5==0)
	{
		if(space==1) printf(" ");
		printf("5");
		space=1;
	}
	if(a%7==0)
	{
		if(space==1) printf(" ");
		printf("7");
	}
	else if(b>0&&c>0)
		printf("n");
}
int main(int argc, char* argv[])
{
     int a;
	 scanf("%d",&a);
	 if((a%7==0)&&(a%3==0)&&(a%5==0))
	 {
		 printf("3 5 7");
	 }
	 else if((a%3==0)&&(a%5==0))
     {
		 printf("3 5");
     }
	 else if((a%5==0)&&(a%7==0))
	 {
		 printf("5 7");
	 }
	 else if((a%3==0)&&(a%7==0))
	 {
		 printf("3 7");
	 }
	 else if(a%3==0)
	 {
		 printf("3");
	 }
     else if(a%5==0)
	 {
		 printf("5");
	 }
	 else if(a%7==0)
	 {
		 printf("7");
	 }
	 else 
	 {
		 printf("n");

	 }
	 
	 
	 
	 return 0;
}
void main()
{
   int a,x,y,z;
   x=y=z=0;
   scanf("%d",&a);
   if(a%3==0) x=1;
   if(a%5==0) y=1;
   if(a%7==0) z=1;
   if(x==1&&y==1&&z==1) printf("3 5 7\n");
	   else if (x==1&&y==1&&z==0) printf("3 5\n");
        else if (x==1&&y==0&&z==1) printf("3 7\n");
 else if (x==0&&y==1&&z==1) printf("5 7\n");
 else if (x==1&&y==0&&z==0) printf("3\n");
 else if (x==0&&y==1&&z==0) printf("5\n");
else if (x==0&&y==0&&z==1) printf("7\n");
 else  printf("n\n");
}
void main()
{
 int n,i,f=0;
 scanf("%d",&n);
 for (i=3;i<=7;i=i+2)
   if (n%i==0)
	 {
	 f=1;
	 printf("%d",i);
	 break;
	 }
 for (i=i+2;i<=7;i=i+2)
   if (n%i==0)
	 {
	 f=1;
	 printf(" %d",i);
	 }
 if (f==0)
   printf("n");
 printf("\n");
}
int main()
{
	int a,i=0,b[3]={3,5,7};//???????????
	cin>>a;
	if(a%3==0&&a%5==0&&a%7==0)
		cout<<"3"<<" "<<"5"<<" "<<"7";
	else if(a%3==0&&a%7==0&&a%5!=0)
		cout<<"3"<<" "<<"7";
	else if(a%3!=0&&a%5==0&&a%7==0)
		cout<<"5"<<" "<<"7";
	else if(a%3==0&&a%5==0&&a%7!=0)
		cout<<"3"<<" "<<"5";
	else if(a%3==0&&a%5!=0&&a%7!=0)
		cout<<"3";
	else if(a%3!=0&&a%5==0&&a%7!=0)
		cout<<"5";
	else if(a%3!=0&&a%5!=0&&a%7==0)
		cout<<"7";
	else if(a%3!=0&&a%5!=0&&a%7!=0) //?????3,5,7?????
		cout<<"n";
	return 0;//????? 
}
void main()
{
	int n,a=0,b=0,c=0;
	scanf("%d",&n);
	if(n%3==0) 
	{
		printf("3");
	}
	else a=1;
	if(n%5==0&&a==0) 
	{
		printf(" 5");
	}
	else if(n%5==0&&a==1) printf("5");
	else b=1;
	if(n%7==0&&(a*b==0)) 
	{
		printf(" 7");
	}
	else if(n%7==0&&(a*b==1)) printf("7");
	else c=1;
	if(a*b*c) printf("n");
}
int main()
{
	int n;
	scanf("%d",&n);
	    if(n%105==0){printf("3 5 7");return 0;}

		if(n%15==0){printf("3 5");return 0;}
	    if(n%21==0){printf("3 7");return 0;}
	    if(n%35==0){printf("5 7");return 0;}
		if (n%3==0){printf("3");return 0;}
		if (n%5==0){printf("5");return 0;}
		if (n%7==0){printf("7");return 0;}
	    if(n%3!=0&&n%5!=0&&n%7!=0){printf("n");return 0;}

}
int main()
{
 int n;
 cin>>n;
 if ((n%3==0)&&(n%5==0)&&(n%7==0))
    cout<<"3 5 7";
 else if ((n%3!=0)&&(n%5==0)&&(n%7==0))
	cout<<"5 7";
 else if ((n%3==0)&&(n%5!=0)&&(n%7==0))
    cout<<"3 7";
 else if ((n%3==0)&&(n%5==0)&&(n%7!=0))
	cout<<"3 5";
 else if ((n%3==0)&&(n%5!=0)&&(n%7!=0))
	cout<<"3";
 else if ((n%3!=0)&&(n%5!=0)&&(n%7==0))
 	cout<<"7";
 else if ((n%3!=0)&&(n%7!=0)&&(n%5==0))
	cout<<"5";
 else
	cout<<"n";
 cin.get();
 cin.get();
 cin.get();
 return 0;
}
int main()
  {int a,b,c,d;
   scanf("%d",&a);
   b=a%3;
   c=a%5;
   d=a%7;
   if (b==0)
     {printf("3");
     if (c==0)
        printf(" 5");
     if (d==0)
        printf(" 7");
      }   
   else if(c==0)
        {printf("5");
         if(d==0)
           printf(" 7");
         }
        else if(d==0)
             printf("7");
             else
             printf("n");
  return 0;
  }
int main()
{
 int n,flag=0;
 cin>>n;
 if(n%3==0)
 {cout<<3;
  flag=1;}
 if(n%5==0)
 {if(flag)
  {cout<<" ";}
  cout<<5;
  flag=1;}
 if(n%7==0)
 {if(flag)
  {cout<<" ";}
  cout<<7;}
 if(n%3!=0&&n%5!=0&&n%7!=0)
 {cout<<"n";}
return 0;
}
int main()
{
    int n, a, b, c;
    
    cin >> n;
    
    a = n%3;
    b = n%5;
    c = n%7;
    
    if(!a && !b && !c) 
    {
        cout << 3 << " " << 5 << " " << 7;
    }
    else if(!a && !b) 
    {
        cout << 3 << " " <<5;
    }
    else if(!a && !c) 
    {
        cout << 3 << " " << 7;
    }
    else if(!b && !c) 
    {
        cout << 5 << " " << 7;
    }
    else if(!a) 
    {
        cout << 3;
    }
    else if(!b) 
    {
        cout << 5;
    }
    else if(!c) 
    {
        cout << 7;
    }
    else cout << 'n';
    
    return 0;
}
int main()
{
    int k,x1=0,x2=0,x3=0,sum;
    cin>>k;
    if(k%3==0) x1=3;
    if(k%5==0) x2=5;
    if(k%7==0) x3=7;
    sum=x1+x2+x3;
      if(sum==0) cout<<"n";
       if(sum==3) cout<< 3;
      if(sum==5) cout<< 5;
      if(sum==7) cout<< 7;
       if(sum==8) cout<< 3<<" "<< 5;
       if(sum==10) cout<< 3<<" "<< 7;
      if(sum==12) cout<< 5<<" "<< 7;
       if(sum==15) cout<< 3<<" "<< 5<<" "<< 7;
       return 0;
       }
int main()
{
  int n;
  int a,b,c;
  scanf("%d",&n);

  a = n%3;
  b = n%5;
  c = n%7;

  if(a==0&&b==0&&c==0)
    {
       printf("3 5 7");
    }
  else
    {
       if(b==0&&c==0)
         {
             printf("5 7");
         }  
       if(a==0&&c==0)
         {
             printf("3 7");
         }
       if(a==0&&b==0)
         {
             printf("3 5");
         }
       if(a*b*c==0&&a>0&&b>0)        
        {
             printf("7");
         }
       if(a*b*c==0&&a>0&&c>0)        
        {
             printf("5");
         }
       if(a*b*c==0&&c>0&&b>0)        
        {
             printf("3");
         }
       if(a*b*c>0)
         {
              printf("n");
         }        
     }
return 0;
}
int main()
{
    int a;
    int r=0;
    
    cin>>a;
    
    if(a%3==0)
    r=r+3;     
    
    if(a%5==0)
    r=r+5;
    
    if(a%7==0)
    r=r+7;           
    
    if(r==3|r==5|r==7)
    cout<<r<<endl;
    
    if(r==8)
    cout<<"3 5"<<endl;
    
    if(r==10)
    cout<<"3 7"<<endl;
    
    if(r==12)
    cout<<"5 7"<<endl;
    
    if(r==15)
    cout<<"3 5 7"<<endl;
    
    if((a%3)*(a%5)*(a%7)!=0)
    cout<<"n"<<endl;
    

    
    return 0;
}
void main()
{
  int n,a,b,c;
  scanf("%d",&n);
  a=n%3;
  b=n%5;
  c=n%7;
  if (a==0&&b==0)
  {
    printf("3 5");
    if (c==0)
      printf(" 7");
  }
  if (a==0&&b!=0)
  {
    printf("3");
    if (c==0)
      printf(" 7");
  }
  if (a!=0&&b==0)
  {
    printf("5");
    if (c==0)
      printf(" 7");
  }
  if (a!=0&&b!=0)
  {
    if (c==0)
      printf("7");
    else
      printf("n");
  }
}
int flag;

void out_put(int num)
{
	++flag;
	if (flag != 1) cout << " ";
	cout << num;
	return;
}

int main()
{
	int n;
	flag = 0;
	cin >> n;
	if (n % 3 == 0) out_put(3);
	if (n % 5 == 0) out_put(5);
	if (n % 7 == 0) out_put(7);
	if (flag == 0) cout << "n";
	return 0;
}
//********************************
//*??3,5,7????   **
//*?????? 1200012784 **
//*???2012.9.28  **
//********************************

int main()
{
	int num;         //??????num??????
	cin >> num;      //??num
	if (num % 3 == 0)//??3????num
	{
		cout << 3;   //?????3
		if (!(num % 5) || !(num % 7)) cout << ' ';  //?num???5?7??????????
	}
	if (num % 5 == 0)//??5????num
	{
		cout << 5;   //?????5
		if (!(num % 7)) cout << ' ';  //?num???7???????????
	}
	if (num % 7 == 0) cout << 7;  //?7??num????7
	if (num % 3 && num % 5 && num % 7) cout << 'n';  //?3?5?7?????num????n

    return 0;
}
int main()
{
int n,i,c=0,s[3]={3,5,7};
scanf("%d",&n);
for (i=0;i<3;i++)
	if (n%s[i]==0)
		c++;

if (c==3) printf("3 5 7");
else if (c==0)
		printf("n");
else if (c==1)
		for (i=0;i<3;i++)
		{
			if (n%s[i]==0)
				printf("%d",s[i]);
		}
else if (c==2)
		{
			if (n%3!=0)printf("5 7");
			if (n%5!=0)printf("3 7");
			if (n%7!=0)printf("3 5");
		}
			

return 0;
}
void main()
{int a,b[3],c[3],i,n=0;
 scanf("%d",&a);
 if(a%3==0||a%5==0||a%7==0)
 { if(a%3==0) b[0]=3;
   else b[0]=0;
   if(a%5==0) b[1]=5;
   else b[1]=0;
   if(a%7==0) b[2]=7;
   else b[2]=0;

   for(i=0;i<3;i++)
	   if(b[i]!=0)
	   {c[n]=b[i];
	   n++;
	   }
   for(i=0;i<n-1;i++)
	   printf("%d ",c[i]);
   printf("%d\n",c[n-1]);

 }
  else
	  printf("n\n");
}
int main( )
{
	int a;
	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%5==0)&&(a%7==0)) cout<<"5 7";
	else if(a%3==0) cout<<3;
	else if(a%5==0) cout<<5;
	else if(a%7==0) cout<<7;
	else cout<<'n';
	return 0;
}
int main()
{
    int x,a,b,c;
    scanf("%d",&x);
	a=x%3;
	b=x%5;
	c=x%7;
	if(a==0&&b==0&&c==0){
		printf("3 5 7");
	}else if(a==0&&b==0&&c!=0){
		printf("3 5");
	}else if(a==0&&b!=0&&c==0){
		printf("3 7");
	}else if(a!=0&&b==0&&c==0){
		printf("5 7");
	}else if(a!=0&&b!=0&&c==0){
		printf("7");
	}else if(a!=0&&b==0&&c!=0){
        printf("5");
    }else if(a==0&&b!=0&&c!=0){
		printf("3");
    }else{
		printf("n");
	}
	return 0;
}
//************************************************************
//* ???????3?5?7????.cpp                        *
//* ??????????????????3?5?7??          *
//* ?    ?????                                         *
//* ?    ??2013.9.29                                      *
//************************************************************
int main()
{
	int num ;

	cin >> num ;

	if (num % 3 == 0 )
	{
		if (num % 5 == 0 ||num % 7 == 0)
		{
			cout << 3 << " " ;
	        if (num % 5 == 0 && num % 7 == 0)
		        cout << 5 << " " << 7 << endl ;
		    else 
			{
		    	if (num % 5 == 0 && num % 7 != 0)
			        cout << 5 << endl ;
			    else
			    	cout << 7 << endl ;
			}
		}
	    if (num % 5 != 0 && num % 7 != 0)
		    cout << 3 << endl ;
	}
	else 
		if (num % 5 == 0 ||num % 7 == 0)
		{
			if (num % 5 == 0 && num % 7 == 0)
		        cout << 5 << " " << 7 << endl ;
		    else 
			{
		    	if (num % 5 == 0 && num % 7 != 0)
			        cout << 5 << endl ;
			    else
			    	cout << 7 << endl ;
			}
		}
		else  cout << "n" << endl ;

	return 0 ;
}
//****************************************************
//*  ? ? ?: homework.cpp                          *
//*  ?    ?: ???                                *
//*  ????: 2012?9?24?                         *
//*  ????: ??3?5?7????                   *
//****************************************************

int main(){
	int a[4]; //??a ??n?????3 5 7?? 
	int i,n; //????
	cin >> n; //??n
	for (i=0;i<=3;i++){ //???a 
		a[i]=0;
	}
	if (n % 3 == 0){  //??n???3?? 
		a[1]=3;  //?? 
		a[0]++;  //?? 
	}
	if (n % 5 == 0){  //??n???5??  
		a[2]=5;  //?? 
		a[0]++;  //?? 
	}
	if (n % 7 == 0){  //??n???7??  
		a[3]=7;  //?? 
		a[0]++;  //?? 
	}
	if (a[0]!=0){ //??????3 5 7???? 
		for (i=1;i<=3;i++){ //??N????? 
			if (a[i]!=0){
				a[0]--;   
				if (a[0]!=0) {
					cout << a[i] << ' ';  //????? (???) 
				} 
				else cout << a[i];  //????? (????) 
			}
		}
	} 
	else cout << 'n';//?????'n' 
}
void main()
{
	int a,b,c;
	scanf("%d",&a);
	if(a%3==0&&a%5==0&&a%7==0)printf("3 5 7");
	else if(a%3==0&&a%5==0)printf("3 5");
	else if(a%3==0&&a%7==0)printf("3 7");
	else if(a%5==0&&a%7==0)printf("5 7");
	else if(a%3==0)printf("3");
	else if(a%5==0)printf("5");
	else if(a%7==0)printf("7");
	else printf("n");
}
int main(){
int a,b,c;
scanf("%d",&a);
if(a%3==0)
   if(a%5==0)
      if(a%7==0)
          printf("3 5 7");
      else
          printf("3 5");
   else
       if(a%7==0)
           printf("3 7");
        else
           printf("3");
else
    if(a%5==0)
      if(a%7==0)
          printf("5 7");
      else
          printf("5");
   else
       if(a%7==0)
           printf("7");
        else
           printf("n");
return 0;
}
void main()
{
	int num;
	scanf("%d",&num);
	if(num%3==0)
	{printf("3");}
	if(num%5==0)
	{
		if(num%3==0)
			printf(" 5");
		if(num%3!=0)
			printf("5");
	}
	if(num%7==0)
	{
		if(num%3==0||num%5==0)
			printf(" 7");
		if(num%3!=0&&num%5!=0)
			printf("7");
	}
	if(num%3!=0&&num%5!=0&&num%7!=0) 
	{printf("n");}
}
int main()
{
	int a;
	scanf("%d",&a);
	if(a>=3)
	{if(a%3==0)
	{
		printf("3");
	}
		
		if(a%5==0&&a%3==0)	
		{
			printf(" 5");
		}
		else if(a%5==0&&a%3!=0)
	{
			printf("5");
		}
		
		if(a%7==0&&(a%3==0||a%5==0))
		{
			printf(" 7");
		}
		else if(a%7==0&&(a%3!=0&&a%5!=0))
		{
			printf("7");
	}
		
if(a%7!=0&&a%3!=0&&a%5!=0)
{
	printf("n");
}
	}
else
{
	printf("n");
}
return 0;
}
int main(){
    int i;
    scanf("%d",&i);
    if((i%3==0)&&(i%5==0)&&(i%7==0)){
    printf("%d %d %d",3,5,7);
     }
     if((i%3==0)&&(i%5==0)&&(i%7!=0)){
    printf("%d %d",3,5);
     }
      if((i%3==0)&&(i%5!=0)&&(i%7==0)){
    printf("%d %d",3,7);
     }
      if((i%3!=0)&&(i%5==0)&&(i%7==0)){
    printf("%d %d",5,7);
     } 
    if((i%3==0)&&(i%5!=0)&&(i%7!=0)){
      printf("%d",3);
     } 
    if((i%3!=0)&&(i%5==0)&&(i%7!=0)){
      printf("%d",5);
     } 
    if((i%3!=0)&&(i%5!=0)&&(i%7==0)){
      printf("%d",7);
     }
    if((i%3!=0)&&(i%5!=0)&&(i%7!=0)){
     printf("n");
     }
     return 0;
}
int main(int argc, char* argv[])
{
int a,b,c,d;
scanf("%d",&a);	
b=a%3;
c=a%5;
d=a%7;
if(b==0&&c==0&&d==0)
{printf("3 5 7");}
else if(b==0&&c==0)
{printf("3 5");}
else if(b==0&&d==0)
{printf("3 7");}
else if(c==0&&d==0)
{printf("5 7");}
else if(b==0)
{printf("3");}
else if(c==0)
{printf("5");}
else if(d==0)
{printf("7");}
else
{printf("n");}
	return 0;
}
int main()
{
	double n;  //n??????????

	cin >> n;

	if((int)(n/3) == (n/3)&&(int)(n/5) == (n/5)&&(int)(n/7) == (n/7))
	{
		cout << "3 5 7" << endl;
	}

	else  if((int)(n/3) == (n/3)&&(int)(n/5) == (n/5)&&(int)(n/7) != (n/7))
	{
		cout << "3 5" << endl;
	}

	else  if((int)(n/3) == (n/3)&&(int)(n/5) != (n/5)&&(int)(n/7) == (n/7))
	{
		cout << "3 7" << endl;
	}

	else  if((int)(n/3) != (n/3)&&(int)(n/5) == (n/5)&&(int)(n/7) == (n/7))
	{
		cout << "5 7" << endl;
	}

	else  if((int)(n/3) != (n/3)&&(int)(n/5) != (n/5)&&(int)(n/7) == (n/7))
	{
		cout << "7" << endl;
	}

	else  if((int)(n/3) != (n/3)&&(int)(n/5) == (n/5)&&(int)(n/7) != (n/7))
	{
		cout << "5" << endl;
	}

	else  if((int)(n/3) == (n/3)&&(int)(n/5) != (n=5)&&(int)(n/7) != (n=7))
	{
		cout << "3" << endl;
	}

	else  if((int)(n/3) != (n/3)&&(int)(n/5) != (n/5)&&(int)(n/7) != (n/7))
	{
		cout << "n" << endl;
	}
	return 0;
}
void main()
{
	int n,a,b,c;
	scanf("%d",&n);
	a=n%3;
	b=n%5;
	c=n%7;
	if (a==0)
	{
		if (b==0)
		{
			if (c==0)
				printf("3 5 7");
			else
				printf("3 5");
		}
		else
		{
			if (c==0)
				printf("3 7");
			else
				printf("3");
		}
	}
	else
	{
		if(b==0)
		{
			if (c==0)
				printf("5 7");
			else
				printf("5");
		}
		else
		{
			if (c==0)
				printf("7");
			else
				printf("n");
		}
	}
}
void main()
{
	int num,i=0,j=0;
	scanf("%d",&num);
	if(num%3==0)
	{
		printf("3");
		i=1;
	}
	if(num%5==0)
	{if(i==1)
	{printf(" ");
	printf("5");}
	else if(i==0)
	{printf("5");}
	j=1;
	}
	if(num%7==0)
	{if(i==1||j==1)
	{printf(" ");
	printf("7");}
	else printf("7");
	}
	if(num%3!=0&&num%5!=0&&num%7!=0) 
		printf("n");
}
int main()
{
    int a;
    cin >> a;
    if (a % 3 == 0)
    cout << 3;
    if (a % 5 == 0 && a % 3 == 0)
    cout << ' ' << 5;
    else if (a % 5 == 0)
    cout << 5; 
    if (a % 7 == 0 && a % 3 != 0 && a % 5 != 0)
    cout << 7;
    else if (a % 7 ==0)
    cout << ' ' << 7;
    if (a % 3 != 0 && a % 5 != 0 && a % 7 != 0)
    cout << "n" << endl;
    
    return 0;
}
//*********************************************
// *file:    3.cpp
// *author:  ????1200012986?
// *date:    2012-9-28
// *description:
//         ???????:??3?5?7???? 
//*********************************************
int main() // ??? 
{
	int k; // ??????k
	cin >> k; // ??????
	{
		if (k % 3 == 0 && k % 5 == 0 && k % 7 == 0) // ??k?????3?5?7??
			cout << "3" << " " << "5" << " " << "7" << endl; // ????3 5 7
		else if (k % 3 != 0 && k % 5 != 0 && k % 7 != 0) // ?k????????
			cout << 'n' << endl; // ??????n
	}
		{
			if (k % 15 == 0 && k % 7 != 0) // ?k????3,5??????7??
				cout << "3" << " " << "5" << endl; // ??3,5
			else if (k % 21 == 0 && k % 5 != 0) // ?k????3,7??????5??
				cout << "3" << " " << "7" << endl; // ??3,7
				else if (k % 35 == 0 && k % 3 != 0) // ?k????5,7??????5??
					cout << "5" << " " << "7" << endl; // ??5,7
		}
	
			{
				if (k % 3 != 0 && k % 5 != 0 && k % 7 == 0) // ?k???7??
					cout << "7" << endl; // ??7
				else if (k % 3 != 0 && k % 7 != 0 && k % 5 == 0) // ?k???5??
					cout << "5" << endl; // ??5
					else if (k % 5 != 0 && k % 7 != 0 && k % 3 == 0) // ?k???3??
						cout << "3" << endl; // ??3
			}
	return 0;
} // ?????
int main()
{
int a;
cin>>a;
int s,t,d;
s=(a%3==0);
t=(a%5==0);
d=(a%7==0);
if(s&&t&&d==1) cout<<"3 5 7"<<endl;
if(s&&(!t)&&d==1) cout<<"3 7"<<endl;
if(s&&t&&(!d)==1) cout<<"3 5"<<endl;
if((!s)&&t&&d==1) cout<<"5 7"<<endl;
if((!s)&&(!t)&&d==1) cout<<"7"<<endl;
if((!s)&&t&&(!d)==1) cout<<"5"<<endl;
if(s&&(!t)&&(!d)==1) cout<<"3"<<endl;
if((!s)&&(!t)&&(!d)==1) cout<<"n"<<endl;
return 0;
}
int main()
{
	int a;
	cin>>a;
	if ((a%3!=0)&&(a%5!=0)&&(a%7!=0))
	    cout<<"n"<<endl;
	else
	{
	    if((a%3==0)&&((a%5)*(a%7)!=0))
			cout<<"3";
		if((a%5==0)&&((a%3)*(a%7)!=0))
			cout<<"5";
		if((a%7==0)&&((a%5)*(a%3)!=0))
			cout<<"7";
		if((a%3)+(a%5)+(a%7)==0)
			cout<<"3 5 7";
		if((a%3!=0)&&((a%5)+(a%7)==0))
			cout<<"5 7";
		if((a%5!=0)&&((a%3)+(a%7)==0))
			cout<<"3 7";
		if((a%7!=0)&&((a%5)+(a%3)==0))
			cout<<"3 5";
	}

	return 0;
}
int main(int argc, char* argv[])
{
	int n;
	scanf("%d",&n);
	if(n%3==0&&n%5==0&&n%7==0)
		printf("3 5 7");
    else if(n%5==0&&n%7==0&&n%3!=0)
        printf("5 7");
	else if(n%3==0&&n%7==0&&n%5!=0)
        printf("3 7");
	else if(n%3==0&&n%5==0&&n%7!=0)
        printf("3 5");
	else if(n%3==0)
        printf("3");
	else if(n%5==0)
        printf("5");
	else if(n%7==0)
        printf("7");
	else printf("n");
	return 0;
}
int main(){
	int a;
	scanf("%d",&a);
	if(a%3==0&&a%5==0&&a%7==0){
		printf("3 5 7");
	}else{
		if(a%3==0&&a%5==0&&a%7!=0){
			printf("3 5");
		}else{
			if(a%3==0&&a%5!=0&&a%7==0){
				printf("3 7");
			}else{
				if(a%3!=0&&a%5==0&&a%7==0){
					printf("5 7");
				}else{
					if(a%3==0&&a%5!=0&&a%7!=0){
						printf("3");
					}else{
						if(a%3!=0&&a%5==0&&a%7!=0){
							printf("5");
						}else{
							if(a%3!=0&&a%5!=0&&a%7==0){
								printf("7");
							}else{
									printf("n");
								}
							}
						}
					}
				}
			}
		}
	return 0;
	}
int main()
{
    int n,s=0;
    cin>>n;
    s=3*(n%3==0)+5*(n%5==0)+7*(n%7==0);
    if(s==0)cout<<'n';
    if(s==3)cout<<3;
    if(s==5)cout<<5;
    if(s==7)cout<<7;
    if(s==8)cout<<"3 5";
    if(s==10)cout<<"3 7";
    if(s==12)cout<<"5 7";
    if(s==15)cout<<"3 5 7";
    return 0;
}
void main()
{
	int n,flag1=0,flag2=0,flag3=0;
	scanf("%d",&n);
	if(n%3==0)
	{flag1=1;}
	if(n%5==0)
	{flag2=1;}
	if(n%7==0)
	{flag3=1;}

	if(flag1==1&&flag2==1&&flag3==1)
	{printf("3 5 7");}
    
	if(flag1==1&&flag2==1&&flag3==0)
	{printf("3 5");}

    
	if(flag2==1&&flag3==1&&flag1==0)
	{printf("5 7");}

    
	if(flag1==1&&flag3==1&&flag2==0)
	{printf("3 7");}

	
	if(flag1==0&&flag2==0&&flag3==0)
	{printf("n");}

	if(flag1==1&&flag2==0&&flag3==0)
	{printf("3");}
	if(flag1==0&&flag2==1&&flag3==0)
	{printf("5");}
	if(flag1==0&&flag2==0&&flag3==1)
	{printf("7");}

}
int main()
{
	int x;
	cin >> x;
	if (x % 3 == 0)
	{
		if (x % 5 == 0)
		{
			if (x % 7 == 0)
				cout << "3" << " " << "5" << " " << "7" << endl;
			else
				cout << "3" << " " << "5" << endl;
		}
		else
		{
			if (x % 7 == 0)
				cout << "3" << " " << "7" << endl;
			else
				cout << "3" << endl;
		}
	}
	else
	{
		if (x % 5 == 0)
		{
			if (x % 7 == 0)
				cout << "5" << " " << "7" << endl;
			else
				cout << "5" << endl;
		}
		else
		{
			if (x % 7 == 0)
				cout << "7" << endl;
			else
				cout << "n" << endl;
		}
	}
	return 0;
}
void main()
{
	int i;
	scanf("%d",&i);
	if(i%3==0)
		printf("3");
	if(i%5==0){
		if(i%3)
		    printf("5");
		else
			printf(" 5");
	}
	if(i%7==0){
		if(i%3==0||i%5==0)
		    printf(" 7");
		else
			printf("7");
	}
	if(i%3&&i%5&&i%7)
	printf("n");
}
//**********************************
//*?????3?5?7???? **
//*?????? 1300012722 **
//*???2013.9.27 **
//**********************************
int main()
{
	int x;

	cin >> x;                               //????

	if(x%3==0)                              //????????3????
	{
		cout << "3" ;           
	    if(x%5==0 )                         //????????5??
		cout << " 5" ;             
        if(x%7==0)                          //????????7??
		cout << " 7" ;   
	}

	else if(x%5==0)                         //????????5??
	{
		cout << "5" ;
		if(x%7==0)                          //????????7??
			cout << " 7" ;
	}
	else if(x%7==0)                         //????????7??
		cout << "7";
	else 
		cout << "n";

	cout << endl;

	return 0;
}
int main()
{
	int a;
	scanf("%d",&a);
	if(a%3==0)
	{
		if(a%5==0)
		{
			if(a%7==0)
			{
				printf("3 5 7");
			}
			else{
				printf("3 5");
			}
		}
		else if(a%7==0){
			printf("3 7");
		}
		else
		{
			printf("3");
		}
	}
	else if(a%3!=0&&a%5==0)
	{
		if(a%7==0)
		{

			printf("5 7");
		}
		else{
			printf("5");
		}
	}
	else if(a%7==0){
		printf("7");
	}
	else{
		printf("n");
	}
	return 0;
}
int main()
{
    int i;
	scanf("%d",&i);
	if(i%3==0)

	 {
 printf("3");
     if(i%5==0)
		 printf(" 5");
	      if(i%7==0)
		    printf(" 7");
	 }
	 if(i%3>0)
     {if(i%5==0)
	 {printf("5");
	      if(i%7==0)
			  printf(" 7");}
	 if(i%5>0)
	 {if(i%7==0)
			  printf("7");}
	 }
	 if(i%3!=0 && i%5!=0 && i%7!=0)
		 printf("n"); 
return 0;
}
int main()
{
    int n,tot=0,b=0;
    scanf("%d",&n);
    if(!(n%3))  tot++;
    if(!(n%5))  tot++;
    if(!(n%7))  tot++;
    if(!(n%3))
    {
        printf("3");
        if(tot-1)
        {
            putchar(' ');
            tot--;
        }
        b=1;
    }
    if(!(n%5))
    {
        printf("5");
        if(tot-1)
        {
            putchar(' ');
            tot--;
        }
        b=1;
    }
    if(!(n%7))
    {
        printf("7");
        if(tot-1)
        {
            putchar(' ');
            tot--;
        }
        b=1;
    }
    if(!b)
    {
        putchar('n');
    }
    putchar('\n');
    return 0;
}