semeru/Code-Code-CloneDetection-POJ104 huggingface dataset:
int main()

{

int a[500];

int i,N;

scanf("%d",&N);

for(i=0;i<N;i++){

         scanf("%d",&a[i]);

}

int b[500];

int j=0;

for(i=0;i<N;i++){

         if(a[i]%2!=0){

                   b[j]=a[i];

                   j++;

         }if(a[i]%2==0){

                   j=j;

         }

 

}

int k,t;

for(k=0;k<j-1;k++){

         for(i=0;i<j-1-k;i++){

                   if(b[i]>b[i+1]){

                            t=b[i];

                       b[i]=b[i+1];

                            b[i+1]=t;

                   }

         }

}for(i=0;i<j-1;i++){

         printf("%d,",b[i]);

}

 

printf("%d",b[j-1]);

 

    return 0;

}
int main(){
	int n,sz[600],szo[600],k=0,a; 
	scanf("%d",&n);
	for(int i=0;i<n;i++){
		scanf("%d",&(sz[i]));
	} 
	for(int j=0;j<n;j++){ 
		if(sz[j]%2!=0){ 
			szo[k]=sz[j]; k++; 
		} 
	} 
	for(int p=1;p<k-1;p++){ 
		for(int o=0;o<k-p;o++){ 
			if(szo[o]>szo[o+1]){
				a=szo[o+1]; szo[o+1]=szo[o]; szo[o]=a; 
			}
		}
	} 
	for(int q=0;q<k;q++){
		if(q==k-1){ printf("%d",szo[q]);
		} else { 
			printf("%d,",szo[q]);
		} 
	}
	return 0;
}
int main()
{int n,i,j,chan,countor;
 scanf("%d",&n);
 int* num=(int*)malloc(n*sizeof(int));
 for(i=0;i<n;i++)
    scanf("%d",num+i);
 
 for(i=0;i<n;i++)
    for(j=0;j<n-i-1;j++)
 {

     if(*(num+j)>*(num+j+1))
     {
         chan=*(num+j);
         *(num+j)=*(num+j+1);
         *(num+j+1)=chan;
     }
 }
for(i=0,countor=0;i<n;i++)
 { 
	 if(*(num+i)%2!=0)
	 countor++;
 }
 for(i=0;i<n;i++)
 { 
	 if(*(num+i)%2==0)
		 continue;
	 else
	 {  
		 countor--;
		 if(countor==0) printf("%d",*(num+i));
		 else printf("%d,",*(num+i));
	 }
 }
return 0;

}
void main()
{
    int a[100],n,i,j,x,t=0;
    scanf("%d",&n);
    for(i=0;i<n;i++)
    scanf("%d",&a[i]);
    for(i=0;i<n;i++)
    {  
        for(j=i+1;j<n;j++)
        {
             if(a[i]>a[j])
             {  
                  x=a[i];
                  a[i]=a[j];
                  a[j]=x;
             }
         }
         if(a[i]%2==1)
         {
         if(t==1)
         printf(",");
         printf("%d",a[i]);
         t=1;
         }
}
     }
/*
* ????1000012865_33
* ??????
* ???2010-11-3
* ??:????????
*/
int main()
{
	int N,n[501] = {0},m,a = 0,i;
	cin >> N;
	for(i = 1; i <= N; i++)
		cin >> n[i];
	for(i = 1; i <= N; i++)
		for(int j = 1; j <= N - i; j++)
			if(n[j] > n[j + 1])
				{
				m = n[j + 1];
				n[j + 1] = n[j];
				n[j] = m;
				}
	for(i = 1,m = 0; i <= N -1; i++)
		if(n[i] % 2 != 0)
			m++;
	for(i = 1;a < m - 1; i++)
		if(n[i] % 2 != 0)
			{
			cout << n[i] << ',';
			a++;
			}
	for(i; i <= N; i++)
		if(n[i] % 2 != 0)
			cout << n[i] << endl;
	return 0;
}
int main()
{
	int n,i,k,j,e,m=0,x=0;
	int a[500]={0},b[500]={0};
	scanf("%d",&n);
	for(i=0;i<n;i++)
		scanf("%d",&a[i]);
	for(j=0;j<n;j++)
	{
		for(i=x;i<n;i++)
		{
			if(a[i]%2!=0)
			{
				x=i+1;
				b[j]=a[i];
				m++;
				break;
			
			}
			
		}
	}
	for(k=1;k<=m;k++)
	{
		for(j=0;j<m-k;j++)
		{
			if(b[j]>b[j+1])
			{
				e=b[j+1];
				b[j+1]=b[j];
				b[j]=e;
			}
		}
		
	}
	for(j=0;j<m-1;j++)
	printf("%d,",b[j]);
	printf("%d\n",b[m-1]);
		
	return 0;
}
int main()
{
	int i1=1,i,j=1,j1,j2,n,a[500],b[500],x=0;
	scanf("%d",&n);
	for(i=1;i<=n;i++)
	{
		scanf("%d",&a[i]);
		if(a[i]%2==1)
		{
			b[j]=a[i];
			j++;
		}
	}
	for(j1=1;j1<j;j1++)
	{
		for(j2=1;j2<j-j1;j2++)
		{
			if(b[j2]>b[j2+1])
			{
				x=b[j2];
				b[j2]=b[j2+1];
				b[j2+1]=x;
			}
		}
	}
	printf("%d",b[1]);
	for(i1=2;i1<j;i1++)
	{
		printf(",%d",b[i1]);
	}
	return 0;
}
void sort (int a[],int n)
{
    int i,j,t;
    for(i=0;i<n;i++)
    {
        for(j=0;j<n-i-1;j++)
        {
            if(a[j]>a[j+1])
            {
                t=a[j];a[j]=a[j+1];a[j+1]=t;
            }
        }
    }
}
int main (){
    int a[500],b[500],n,i,j=0;
    scanf("%d",&n);
    for(i=0;i<n;i++)
    scanf("%d",&a[i]);
    for(i=0;i<n;i++)
    {
        if(a[i]%2!=0)
        {
            b[j]=a[i];j++;
        }
    }
    sort(b,j);
    for(i=0;i<j-1;i++)
    {
        printf("%d,",b[i]);
    }
    printf("%d",b[i]);
    return 0;
}
int main(){
    int n,i,k,e,c;
    int a[LEN],d[LEN];
    c=0;
    scanf("%d",&n);
    for (i=0;i<n;i++){
       scanf("%d",&a[i]);
}
    for(k=1;k<n-1;k++){
    for(i=0;i<n-k;i++){
       if (a[i]>a[i+1]){
       e=a[i];
       a[i]=a[i+1];
       a[i+1]=e;
       };
    };
    }
    for (i=0;i<n;i++){
        if(a[i]%2==1){
d[c]=a[i];c=c+1;
       }
}
for (i=0;i<c;i++){
    if(i!=c-1){
printf("%d,",d[i]);
}
else{
 printf("%d",d[i]);
}
}
return 0;
}
int main(){
	
	int N,e,h;
	int s[500],j[500];
	int i=0,k=0,g=1;
	scanf("%d",&N);
	for(i=0;i<N;i++){
		scanf("%d",&(s[i]));
		if(s[i]%2!=0){
			j[k]=s[i];
			k++;
		}
	}
	h=k;
	k=0;
   for(g=1;g<=h;g++){
		for(k=0;k<h-g;k++){
			if(j[k]>j[k+1]){
				e=j[k+1];
				j[k+1]=j[k];
				j[k]=e;
			}
		}
	}
   k=0;
  for(k=0;k<h;k++){
	  

           if(k<h-1){
		  printf("%d,",j[k]);
	  }
	  if(k==h-1){
		  printf("%d",j[k]);

	  }
	}

	return 0;

}
int main(){
	int N,a[500],i,b[500],j=0,m,e,n;
	scanf("%d",&N);
	for(i=0;i<N;i++){
		scanf("%d",&a[i]);
		if(a[i]%2==1){
			e=a[i];
			b[j]=e;
			j++;
		}
	}
	n=j;
	for(int k=1;k<=n;k++){
		for(i=0;i<n-k;i++){
			if(b[i]>b[i+1]){
				m=b[i];
			    b[i]=b[i+1];
			    b[i + 1]=m;
			}
		}
	}
	for(i=0;i<n;i++)
		if(b[i]<b[n-1])
		printf("%d,",b[i]);
		else printf("%d",b[i]);
	return 0;
}
int main()
{
	int n,e,j=0,i,k,s,x=0;
	int a[500],b[100];
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d",&a[i]);
		s=a[i]%2;
		switch(s){
		case 0:
			break;
		case 1:
			b[j]=a[i];
			j++;
			x++;
			break;
		}
	}
	for(k=1;k<=x;k++){
		for(j=0;j<x-k;j++){
			if(b[j]>b[j+1]){
				e=b[j];
				b[j]=b[j+1];
				b[j+1]=e;
			}
		}
	}
	for(j=0;j<x-1;j++){
		printf("%d,",b[j]);
	}
	printf("%d",b[x-1]);
	return 0;
}
int main(){
	int n,j,i,k=0,e,g=0;
	int sz[500],js[500];
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d",&(sz[i]));
		if(sz[i]%2==1){
			k++;
			js[g]=sz[i];
			g++;
		}
	}for(int i=1;i<k;i++){
		 for(int j=0;j<k-i;j++){
		 		 if(js[j]>js[j+1]){
				 		e=js[j];
						 js[j]=js[j+1];
						 js[j+1]=e;			 
		 		 }
		 }
}for(i=0;i<k-1;i++){
printf("%d,",js[i]);
}printf("%d",js[k-1]);
	return 0;
}
int main() {
    int n,i,k,m,x,p;
    scanf("%d",&n);
    int a[n];
    k=0;
    for(i=1;i<=n;i++) {
        scanf("%d",&m);
        if(m%2==1) {
            k++; a[k]=m; 
        }
    }
  for(p=0;p<k;p++) {
      for(i=1;i<=k-p;i++) {
          if(a[i]<a[i+1]) {
              x=a[i+1];
              a[i+1]=a[i];
              a[i]=x;
          }
      }
  }
  for(i=1;i<k;i++) {
      printf("%d,",a[k-i+1]) ;
  }
  printf("%d",a[1]) ;
  return 0 ;
  
  
  
}
int main()
{
	int n,j,i,t,a[1000],b[1000],m=0,temp=0;
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{   
		scanf("%d",&(a[i]));
	}
	for(i=0;i<n;i++)
	{
		for(j=n-1;j>i;j--)
		{
			if(a[j]<a[j-1])
			{
				t=a[j];
			a[j]=a[j-1];
			a[j-1]=t;
			}
		}
	}
	for(i=0;i<n;i++)
	{   if(a[i]%2!=0)
			{
		b[m]=a[i];
		m++;
	    temp++;
	}
	
	}
	for(m=0;m<temp;m++)
	{
		if(b[m+1]>b[m])
		{
	     printf("%d,",b[m]);
		}
		else
		{
			printf("%d",b[m]);
		}
	}
		return 0;
	

}
int main(){
  int N,a[500],b[500];
  int i,j,m,r;
  scanf("%d\n",&N);
  for(i=0;i<N;i++){
   scanf("%d ",&a[i]);
   }
   scanf("%d\n",&a[N-1]);
   for(j=0,i=0,m=0;i<N;i++){
    if(a[i]!=2&&a[i]%2!=0){
     b[j]=a[i];
     j++;
     m++;
     }
    }
  for(i=0;i<m;i++){
    for(j=m-1;j>i;j--){
     if(b[j]<b[j-1]){
      r=b[j];
      b[j]=b[j-1];
      b[j-1]=r;
     }
    }
   }
    printf("%d",b[0]);
    for(j=1;j<m;j++){
     printf(",%d",b[j]);
    }
     return 0;
}
int main(){
    int N,sz[500],j=0,e,yz[500];
    scanf("%d",&N);
    for(int i=0;i<N;i++){
        scanf("%d",&sz[i]);
    }
    for(int i=0;i<N;i++){
        if(sz[i]%2!=0){
            yz[j]=sz[i];
            j++;
        }
    }
    for(int p=1;p<j;p++){
        for(int q=0;q<j-p;q++){
            if(yz[q]>yz[q+1]){
                e=yz[q+1];
                yz[q+1]=yz[q];
                yz[q]=e;
            }
        }
    }
    for(int t=0;t<j;t++){
        if(t!=j-1){
            printf("%d,",yz[t]);
        } else{
            printf("%d",yz[t]);
        }
    }
    return 0;
}
int main(){
	int n;
	int zzd[501];
	int hzy[501];
	int wh[501];
	int zjz[501];
	int i;
	int a;
	int m;
	int g;
	int s;
	int k;
	a=0;
	s=0;
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		scanf("%d",&zzd[i]);
	}
	for(i=0;i<n;i++)
	{
		if(zzd[i]%2==1){
			hzy[a]=zzd[i];
			a++;
		}
	}
	for(k=0;k<a;k++)
	{
		for(i=0;i<a;i++)
		{
		 if(i==0){
			m=hzy[i];
		}
		 if(i>0){
			if(m<hzy[i]){
				m=hzy[i];
			    g=i;
		}   
		}
		 if(i==a-1){
			wh[s]=m;
			s++;
			hzy[g]=0;
		}
		}
	}
	for(i=0;i<a;i++)
	{
		zjz[a-i-1]=wh[i];
	}
	for(i=0;i<a-1;i++)
	{
	printf("%d,",zjz[i]);
	}
	if(i=a-1){
		printf("%d",zjz[i]);
	}
	
	return 0;
}
int main(){
    int sz[1000];
    int a[1000];
    int n,temp;
    int m=0;
    int j=0;
    char c=',';
    scanf("%d",&n);
    for(int i=0;i<n;i++){
        scanf("%d",&sz[i]);
    }
    
    for(int i=0;i<n;i++){
        if(sz[i]%2==1){a[j]=sz[i];
        j++;
    }for(int p=0;p<j;p++){
    for(int i=0;i<j-1-p;i++){
      if(a[i]>a[i+1]){
            temp=a[i+1];
          a[i+1]=a[i];
            a[i]=temp;
        }
    }
    }
    
}

for(int i=0;i<j;i++){
    if(i<j-1){
    printf("%d%c",a[i],c);}
    else{printf("%d",a[i]);
    
    }
}
}
int main()
{
	int N = 0;
	cin >> N;
	int a[N];
	int i = 0, j = 0, k = 0, t = 0;
	
	for ( int i = 0; i < N; i++ )
	{
		cin >> k;
		if ( k%2 == 1)
		{
			a[j] = k;
			j++;
		}
	}
	
	for ( int i = 0; i < j; i++ )
		for ( int k = i + 1; k < j; k++ )
			if ( a[i] > a[k] )
			{
				t = a[i];
				a[i] = a[k];
				a[k] = t;
			}
	
	cout << a[0];
	for ( int i = 1; i < j; i++ )
		cout << "," << a[i];
	
	return 0;
}
int main(){
	int e,n,m=0;
	scanf("%d",&n);
int num[500],sz[500];
	for(int i=0;i<n;i++){
	scanf("%d",&(num[i]));
}	
for(int i=1;i<n;i++){
		 for(int j=0;j<n-i;j++){
		 		 if(num[j]>num[j+1]){
				 		e=num[j];
						 num[j]=num[j+1];
						 num[j+1]=e;			 
		 		 }
		 }
}
for(int i=0;i<n;i++){
		if(num[i]%2==1){
						sz[m]=num[i];
						m++;
		}
}
for(int i=0;i<m-1;i++){
		printf("%d,",sz[i]);
}
printf("%d",sz[m-1]);
return 0;	
}
int main()//???
{
	int n,a[1000],b[1000],s=0,d=0,f=0,i=0,j=0;//????
	cin>>n;
	for(i=0;i<n;i++)
	{ 
		cin>>a[i];
		if(a[i]%2==1)
		{b[j]=a[i],j++,d++;}//???????
	}
	for(i=0;i<d-1;i++)
	{
		for(j=i+1;j<d;j++)
		{
			if(b[i]>b[j])
			{f=b[i],b[i]=b[j],b[j]=f;}//?????
		}
	}
	for(j=0;j<d-1;j++)
	{cout<<b[j]<<",";}
	cout<<b[d-1];//????
	return 0;
}
main(){
 int sz[300],a[300];
    char x;
    int n,i,j,k,p,q;
    x=',';
    n=0;
    scanf("%d",&q);
    for(i=0;i<q;i++){
      scanf("%d",&a[i]);
      if(a[i]%2==1){
        sz[n]=a[i];
        n++;
      }
    }
    n=n-1;
    for(j=1;j<=n;j++){
    for(i=0;i<n;i++){
      k=i+1;
      if(sz[k]<sz[i]){
        p=sz[k];
        sz[k]=sz[i];
        sz[i]=p;
      }
    }
    }
    for(i=0;i<=n;i++){
      if(i<n){
        printf("%d",sz[i]);
        printf("%c",x);
      }else{
        printf("%d",sz[i]);
      }
    }
return 0;
}
int main(){
	int N,i,k,e,h,t;
	h=0;
	int a[500];
	int b[500];
	int c[500]={0};
	scanf("%d",&N);
	for(i=0;i<N;i++){
		scanf("%d",&a[i]);
		 if(a[i]%2!=0){
	         c[i]=1;
			 b[h]=a[i];
             h+=c[i];
		}

	}
	t=h;
	for(k=1;k<=t;k++){
		for(h=0;h<t-k;h++){
			if(b[h]>b[h+1]){
				e=b[h+1];
				b[h+1]=b[h];
				b[h]=e;
			}
		}
	}
    for(h=0;h<t;h++){
		if(h==t-1){
		 printf("%d",b[h]);
		}else{
		 printf("%d%c",b[h],',');
		}
	}
	return 0;
}
int main()
{
   int n,i,j,k,m,a[501],b[501];
   j=0; 
   scanf("%d",&n);
   for(i=0;i<n;i++)
   {
		scanf("%d",&a[i]); 
	} 
	for(k=0;k<250;k++)
	{
		for(i=0;i<n;i++)
		{
			if(a[i]==2*k+1)
			{
				 b[j]=a[i];
				 j+=1; 
			} 
		} 
	}
	if(j!=0)
	{ 
	  for(m=0;m<j-1;m++)
	  {
		printf("%d,",b[m]); 
	  }
	  printf("%d",b[j-1]); 
	} 
	scanf("%d",&n); 
	return 0; 

}
int main(){
    int N,i,m,k,e;
    int a[500];
    scanf("%d",&N);
    for(i=0;i<N;i++){
        scanf("%d ",&a[i]);
    }
    for(int k=1;k<=N;k++){
        for(i=0;i<N-k;i++){
            if(a[i]>a[i+1]){
                e=a[i+1];
                a[i+1]=a[i];
                a[i]=e;
            }
        }
    }
    int first;
    for(first=0;first<N;first++){
        if(a[first]%2==1){
            printf("%d",a[first]);
            break;
        }
    }
    for(i=first+1;i<N;i++){
        if(a[i]%2==1){
            printf(",%d",a[i]);
        }
    }
    return 0;
}
int main()
{
  int n,t=500,q=0,w,m=0;
  cin>>n;
  int a[n],b[t];
  for(int i=0;i<n;i++)
    cin>>a[i];
  for(int j=0;j<n;j++)
    if(a[j]%2!=0)
      {
       b[m]=a[j];
       q++;
       m++;
      }
  for(int i=1;i<=q-1;i++)
    for(int j=0;j<=q-i;j++)
      if(b[j]>b[j+1])
        {
         w=b[j];
         b[j]=b[j+1];
         b[j+1]=w;
        }    
  cout<<b[0];
  for(int k=1;k<=q-1;k++)
    cout<<","<<b[k];
  
  return 0;
}
int main(){
	int n,a[1000],i,w=0,t,r;
	scanf("%d",&n);
	for(i=0;i<=n-1;i=i+1){
		scanf("%d",&a[i]);
	}
    int b[1000];
	for(i=0;i<=n;i=i+1){
		if(a[i]%2==1){
			b[w]=a[i];
			w=w+1;
		}
	}

	for(r=w-1;r>=1;r=r-1){
	    for(i=0;i<=w-1-1;i=i+1){
			if (b[i]>b[i+1]){
				t=b[i];
				b[i]=b[i+1];
				b[i+1]=t;
			}
		}
	}
		printf("%d",b[0]);
		for(i=1;i<=w-1;i=i+1){
		printf(",%d",b[i]);
		}
	return 0;
}
int main()
{
	int N;
	cin>>N;
	int i,k,num[500];
	for(i=0;i<N;++i) 
		cin>>num[i];
	for(i=0;i<N;++i)
	{
		if(num[i]%2==0) 
			num[i]=0;
	}
	sort(&num[0],&num[0]+N);
    for(i=0;i<N;++i)
	{
		if(num[i]!=0)
		{
			cout<<num[i];
			k=i;
			break;
		}
	}
	for(i=k+1;i<N;++i)
		cout<<","<<num[i];
	return 0;
}
int main()
{
	int i,j,k,n,m,li,ri,a[501];
scanf("%d",&n);
j=-1;a[0]=0;
for(i=0;i<n;i++){
scanf("%d",&m);
if(m%2==1){
j++;
a[j]=m;
if(j>0){
	li=j-1;ri=j;
	while((a[li]>a[ri])&&(li>=0)){
	k=a[ri];
	a[ri]=a[li];
	a[li]=k;
	ri--;
	li--;
	}
}
}
}
for(i=0;i<j;i++){
printf("%d,",a[i]);
}
printf("%d",a[j]);
return 0;
}
int main(int argc, char* argv[])
{   int b,a[500],i=0,c=0,d[500],e,f=0;
    scanf("%d",&b);
    for(i=0;i<b;i++){
	   scanf("%d",&a[i]);
	}

	for(i=0;i<b;i++){
		if(a[i]%2!=0){
			d[c]=a[i];
			c++;
		}
	}
    for(f=c;f>1;f--){
		for(i=0;i<f-1;i++){
			if(d[i]>d[i+1]){
				e=d[i+1];
				d[i+1]=d[i];
				d[i]=e;
			}
		}
	    
	}
	for(i=0;i<c;i++){
		if(i==c-1){printf("%d",d[i]);}else{
			printf("%d,",d[i]);}
	}	
	return 0;
}
int main(){
int i,j,k,N;
j=0;
int sz[10000];
scanf("%d",&N);
for(i=0;i<N;i++){
		scanf("%d",&(sz[i]));
}
for(i=0;i<N;i++){
   if(sz[i]%2!=0){
sz[j]=sz[i];
j++;
}
}
int maxIndex,e;
for(k=1;k<=j;k++){
  maxIndex=0;
for(int i=0;i<=j-k;i++){
  if(sz[i]>sz[maxIndex]){
     maxIndex=i;
}
}
if(maxIndex!=j-k){
   e=sz[maxIndex];
   sz[maxIndex]=sz[j-k];
   sz[j-k]=e;
}
}
printf("%d", sz[0]);
for(i=1;i<j;i++){
  printf(",%d",sz[i]);}
return 0;
}
int data[1000];
int comma;

int main(int argc, const char * argv[])
{
    int n;
    cin >> n;
    for (int i = 0; i < n; i++) {
        cin >> data[i];
    }
    sort(data, data + n);
    for (int i = 0; i < n; i++) {
        if (data[i] / 2 * 2 != data[i]) {
            if (comma) {
                cout << ",";
            }
            comma = true;
            cout << data[i];
        }
    }
}
int main(){
int sz[500],szz[500];
int n,e,s=0;
int i,j,k;
scanf("%d",&n);
for(i=0;i<n;i++){
scanf("%d",&sz[i]);
	if(sz[i]%2!=0){
	s=s+1;
	}
}
j=0;
for(i=0;i<n;i++){
if(sz[i]%2!=0){
szz[j]=sz[i];
j++;
}
}
for(k=1;k<=s;k++){
	for(j=0;j<s-k;j++){
		if(szz[j]>szz[j+1]){
		e=szz[j+1];
		szz[j+1]=szz[j];
		szz[j]=e;
		}
	}
}
for(j=0;j<s-1;j++){
printf("%d,",szz[j]);
}
if(j==s-1){
printf("%d",szz[j]);
}
return 0;
}
int main() //?~
{
	int i,j,s,t,n,a[500],b[500];
	scanf("%d",&n);
	scanf("%d",&a[0]);
	for(i=1;i<n;i++){
		scanf(" %d",&a[i]);}
	for(j=0,i=0;i<n;i++){
		if(a[i]%2!=0)
		{b[j]=a[i];
		j++;}
	}
	for(i=0;i<j;i++){

		for(t=0;t<j-1;t++){
			if(b[t]>=b[t+1]){
			s=b[t];
		   b[t]=b[t+1];
		   b[t+1]=s;
			}
		}
	}
	printf("%d",b[0]);
    for(i=1;i<j;i++){
			printf(",%d",b[i]);
	}
	return 0;
}
int main()
{
    int n,s,t,m,j,r,i;
    int a[500],b[500];
    s=0;
    scanf("%d",&n);
    for(i=0;i<n;i++){
        scanf("%d",&a[i]);
        if(a[i]%2!=0){
            b[s]=a[i];
            s++;
        }
    }
    for(j=1;j<s;j++){
        t=b[j];
        for(r=j-1;r>=0;r--){
            if(t<b[r]){
                b[r+1]=b[r];
                b[r]=t;
            }else{
                b[r+1]=t;
                break;
            }
        }
    }
    for(m=0;m<s-1;m++){
        printf("%d,",b[m]);
    }
    printf("%d",b[s-1]);
    return 0;
}
int main ()
{
	int n;
	int a[501];
	int number, k = 1;
	cin >> n;
	for (int i = 1; i <= n; i++)
	{
		cin >> number;
		if (number % 2 == 1)
		{
			a[k] = number;
			k++;
		}
	}
	for (int m = 1; m <= k - 2; m++)
	{
		int p = m;
		for (int l = m + 1; l <= k - 1; l++)
		{
			if (a[p] > a[l])
		{
			int t = a[l];
			a[l] = a[p];
			a[p] = t;
		}
		}
		
	}
	for (int n = 1; n <= k - 1; n++)
	{
		if (n == 1)
			cout << a[n];
		else cout << "," << a[n];
	}
	return 0;
}
int main(){
	int N,a[500],b[500],k,i,j,t;
	k=0;
	scanf("%d",&N);
	i=0;
	while(i<N){
		scanf("%d",&a[i]);
		i=i+1;
	}
	i=0;
    while(i<N){
               if(a[i]%2==1){
                             k=k+1;
                             b[k-1]=a[i];
               }
               i=i+1;
	}
	for(j=0;j<k-1;j=j+1){
                       for(i=0;i<k-j-1;i=i+1){
                                            if(b[i]>b[i+1]){
                                                            t=b[i];
                                                            b[i]=b[i+1];
                                                            b[i+1]=t;
                                            }
                       }
    }
    i=0;
	while(i<k){
               if(i<k-1){
                 printf("%d,",b[i]);
                 i=i+1;
               }
               else{
                 printf("%d",b[i]);
                 i=i+1;
               }
    }
    	scanf("%d",&N);
	return 0;
}
int main(){
   int n,i,d,k,c,j,e;
   scanf("%d",&n);
   int a[n],b[100];
   d=0;
   c=0;
   for(i=0;i<n;i++){
       scanf("%d",&a[i]);
       }
   for(i=0;i<n;i++){
       if(a[i]%2!=0){
          d++;
          }
       }
   for(k=0;k<d;k++){
       for(i=c;i<n;i++){
          if(a[i]%2!=0){
             b[k]=a[i];
             c=i+1;
             break;
             }
          c=i+1;
          }
       }                    
   for(i=0;i<d-1;i++){
      for(k=0;k<d-i-1;k++){
         if(b[k]>b[k+1]){
           e=b[k];            
           b[k]=b[k+1];
           b[k+1]=e;
           }
      }
      }
    for(i=0;i<d;i++){
       if(i!=d-1){
       printf("%d,",b[i]);
       }
       else{
       printf("%d",b[i]);     
       }
       } 
       scanf("%d",&n);  
    return 0;
}
/*??????????
 ?????? 00948344
 ?????2010/12/24
 */



int main(){
	int n,s[500],t[500];         
	cin>>n;
	int i,j,k;
	for(i=0;i<n;i++)
		cin>>s[i];
    int len=0;
	for(i=0;i<n;i++)
		if(s[i]%2!=0)
		{
			t[len]=s[i];
			len++;
		}
	if(len==0)
		return 0;
	for(i=0;i<len-1;i++)
		for(j=0;j<len-1-i;j++)
			if(t[j]>t[j+1])
			{
				k=t[j];
				t[j]=t[j+1];
				t[j+1]=k;
			}
	cout<<t[0];
	for(i=1;i<len;i++)
		cout<<','<<t[i];
	return 0;
}
int main()

{

int n,i,j,t;

char q=',';

    scanf("%d",&n);

int s[500],z[500]={100};

for(i=0;i<n;i++)
{
scanf("%d ",&s[i]);
if(s[i]%2!=0)
{
z[i]=s[i];
}
}

for(i=0;i<n;i++)
{
for(j=n-1;j>0;j--)
{
if(z[j]<z[j-1])
{
t=z[j];

z[j]=z[j-1];

z[j-1]=t;
}
}
}

int m=0;

for(i=0;i<n;i++)
{
if(z[i]==0)continue;

if(z[i]!=0&&m==0)
{
printf("%d",z[i]);

m=1;
}

         else printf("%c%d",q,z[i]);
}

return 0;

}
int main()
{
    int N,i,j,k,m,e,a[500],b[500];
    scanf("%d",&N);
    for(i=0;i<N;i++)
    {
        scanf("%d",&a[i]);
    }
    j=-1;
    m=0;
    for(i=0;i<N;i++)
    {
        if(a[i]%2==1)
        {j++;
        b[j]=a[i]; 
        m++;}
    }
    for(k=0;k<m-1;k++)
    {
        for(j=0;j<m-1-k;j++)
        {
             if(b[j]>b[j+1])
             {
                  e=b[j];
                  b[j]=b[j+1];
                  b[j+1]=e;
             }
        }
    }
    for(j=0;j<m;j++)
    {
        if(j<m-1)
        printf("%d,",b[j]);
        else
        printf("%d",b[j]);
    }
    scanf("%d",1);
    return 0;
}
int main(){
	int sz[500],zs[500];
	int n,i,x=0,c;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d",&sz[i]);
	if(sz[i]%2!=0){
		zs[x]=sz[i];
		x++;}
	}
	for(i=0;i<x-1;i++){
		if(zs[i]>zs[i+1]){
		c=zs[i+1];
		zs[i+1]=zs[i];
        zs[i]=c;
		if(i!=0)i=i-2;
		}
	}
	for(i=0;i<x;i++){
		if(i==0){printf("%d",zs[i]);}else{
		
			printf(",%d",zs[i]);
		}
	
	}
	


return 0;
}
int main(){
	int n,i,a[100],b[100],j,t;
	char c=',';
	scanf("%d",&n);
	for (i=0;i<n;i++){
		b[i]=0;
		scanf("%d",&a[i]);
		if (a[i]%2!=0)
			b[i]=a[i];
		continue;
	}
	for (i=0;i<n-1;i++){
		for (j=i+1;j<n;j++){
			if (b[i]>b[j]){
				t=b[i];
				b[i]=b[j];
				b[j]=t;
			}
		}
	}
	for (i=0;i<n-1;i++){
		if (b[i]!=0)
			printf("%d%c",b[i],c);
		else continue;
	}
	printf("%d",b[n-1]);
	return 0;
}
int main () {
int n,i,s;
scanf ("%d",&n);
int a[n];
int b[n];
s=0;
for(i=0;i<n;i++) {
scanf("%d",&b[i]);
if(b[i]%2!=0) {a[s]=b[i];s++;} }
while (n>0) {n=0;
for (i=0;i<s-1;i++)
if(a[i]>a[i+1])
{a[i]=a[i]+a[i+1];
a[i+1]=a[i]-a[i+1];a[i]=a[i]-a[i+1];n++;} }
for (i=0;i<s-1;i++)
printf("%d,",a[i]);
printf("%d\n",a[s-1]);
return 0;
}
int main(){
    int a[500],n,b[500];
    b[0]=0;
    scanf("%d",&n);
    for(int i=0;i<n;i++){
             scanf("%d",&a[i]);
             } 
    for(int m=1;m<=n;m++){
            b[m]=10000;
            for(int j=0;j<n;j++){
                    if(a[j]%2==1&&a[j]>b[m-1]&&a[j]<b[m])
                      b[m]=a[j];
                    }
            if(m==1)
              printf("%d",b[m]);
            else if(b[m]!=10000)
              printf(",%d",b[m]);
            }
    return 0;
}
int main()
{
  int a[10000],n,i,t,j,m;
  scanf("%d/n",&n);
  m=0;
  for(i=0;i<n;i++)
   {
   scanf("%d",&t);
   if (t%2==1) 
     {
      a[m]=t;
      m=m+1;
      }
   }
  for(j=0;j<m-1;j++)
   for(i=0;i<m-1;i++)
     if(a[i]>a[i+1])
     {t=a[i]; a[i]=a[i+1]; a[i+1]=t;}
  printf("%d",a[0]);
  for(i=1;i<m;i++)
    printf(",%d",a[i]);
    return 0;
}
void Bubble(int a[],int n)
{
	int i,j;
	int temp1;
	for(i=1;i<n;i++)
	{
		for(j=0;j<n-i;j++)
		{
			if(a[j]>a[j+1])
			{
				temp1=a[j];
				a[j]=a[j+1];
			    a[j+1]=temp1;     
			}
		}
	}
}
void main()
{
	int i,n,t=0,a[500],b[500];
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		scanf("%d",&a[i]);
		if(a[i]%2!=0) 
		{
			b[t]=a[i];
		    t++;
		}
    }
    Bubble(b,t);
	for(i=0;i<t;i++)
		printf("%d%c",b[i],(i==t-1)?'\n':',');
}
int main(){
int k,n,i,m,x,y,z,c;
scanf("%d",&n);
int a[n];
int b[n];
x=0;
y=0;
for(i=0;i<n;i++){
scanf("%d",&(a[i]));
}
for(i=0;i<n;i++){
for(m=0;m<n;m++){
if(a[m]<a[i]){
x=x+1;
}
if(a[m]==a[i]){
y=y+1;
}
}
for(z=x;z<=x+y-1;z++){
b[z]=a[i];
}
x=0;
y=0;
}
for(i=0;i<n;i++){
if(b[i]%2!=0){
printf("%d",b[i]);
c=i;
break;
}
}
for(i=c+1;i<n;i++){
if(b[i]%2!=0){
printf(",%d",b[i]);
}
}
return 0;
}
int main(){
	int i,z,n,s[100],k[100],m,e,a;
	scanf("%d",&n);
	for(i=0;i<n;i++){
		scanf("%d",&s[i]);
	}
	z=0;
	for(i=0;i<n;i++){
		if(s[i]%2==1){
			k[z]=s[i];
			z++;
		}
	}
for(a=1;a<=z;a++){
	m=0;
	for(i=0;i<=z-a;i++){
		if(k[i]>k[m]){
			m=i;
		}
		if(m!=z-a){
			e=k[m];
			k[m]=k[z-a];
			k[z-a]=e;
		}
	}
	}
	if(z==1){
		printf("%d",k[0]);
	}else{printf("%d",k[0]);
		for(i=1;i<z;i++){
			
				printf(",%d",k[i]);
							}
	}
return 0;
}
/*??
???????N????500???????????????????????????

????
?2?
?1?? N
?2?? N ?????????????


????
????????????????????
*/
int main()
{
	int n,a[500],b[500];
	cin>>n;int k=1;
	for(int i=1;i<=n;i++)
	{
		cin>>a[i];
		int z=a[i]%2;
		if(z==1)
		{
			b[k]=a[i];k++;//???????
		}
	}

		//?????
		for(int i=1;i<k;i++)
			{
				int p=10000,m;
				for(int j=i;j<k;j++)
					if(b[j]<p) {p=b[j];m=j;}
				int t;
				t=b[i];
				b[i]=b[m];
				b[m]=t;

			}

	for(int i=1;i<k;i++)
	{
		if(i==1) cout<<b[i];
		else cout<<","<<b[i];
	}
	return 0;
	}