https://www.acmicpc.net/problem/1427
import java.util.*;
public class Main {
public static void main(String args[]) {
Scanner s=new Scanner(System.in);
int n=s.nextInt();
String k=n+"";
int m=k.length();
Integer arr[]=new Integer[m];
for(int i=0;i<m;i++){
arr[i]=n%10;
n/=10;
}
Arrays.sort(arr,Collections.reverseOrder());
for(int i=0;i<m;i++){
System.out.print(arr[i]);
}
}
}