#include "partition.h"
#include <bits/stdc++.h>

using namespace std;

#ifndef GIGO_DEBUG
#define cerr if(false)cerr
#endif // GIGO_DEBUG

vector<int> solve(vector<int> a) {
    int n = a.size();
    sort(a.begin(), a.end());

    vector<int> ret;
    for(int i = 0; i < n; i+=2){ ret.push_back(a[i]); }
    for(int i = 1; i < n; i+=2){ ret.push_back(a[i]); }

    return ret;
}
