#include <string>
#include <vector>
#include <algorithm>
using namespace std;
long long solution(long long n)
{
long long answer = 0;
int i;
vector <int> temp;
string s = to_string(n);
string ans;
for(i = 0; i < s.length(); i++)
{
temp.push_back(s[i]);
}
sort(temp.begin(), temp.end(), greater<int>());
for(i = 0; i < temp.size(); i++)
{
ans += temp[i];
}
answer = stoll(ans);
return answer;
}