#include <iostream>
#include <vector>
#include <string.h>
#include <algorithm>

#if 0
#define DEBUG_0331
#endif

static int getNumbers(std::vector<int>& vec);
static int sortNumbers(std::vector<int>& vec);
static void pushNumbers(std::vector<int>& vec);

int main()
{
    std::vector<int> vector;

    getNumbers(vector);
    sortNumbers(vector);
    pushNumbers(vector);
#ifdef DEBUG_0331
    for (int i = 0; i < vector.size(); i++ ) {
        std::cout << vector.at(i) << std::endl;
    }
#endif
    return 0;
}

static int getNumbers(std::vector<int>& vec)
{
    std::string s1("");
    char ss1[512] = {0};
    char *p = NULL;

    if ( 0x00 == &vec ) {
        return 1;
    }

    std::getline(std::cin, s1);

    p = ss1;
    memset(ss1, '\0', sizeof(ss1));
    memcpy(ss1, s1.c_str(), sizeof(ss1));
    // split
    while (*p) {
        if (' ' != *p) {
            vec.push_back(*p - '0');
        }
        p++;
    }

    return 0;
}

static int sortNumbers(std::vector<int>& vec)
{
    if ( 0x00 == &vec ) {
        return 1;
    }

    // sort
    std::sort(vec.begin(), vec.end(), std::greater<int>());

    return 0;
}

static void pushNumbers(std::vector<int>& vec)
{
    if ( 0x00 == &vec ) {
        return;
    }

    for (unsigned int i = 0; i < vec.size(); i++) {
        std::cout << vec.at(i);
        if (vec.size() - 1 == i) {
            std::cout << '\n';
        } else {
            std::cout << ' ';
        }
    }
}