#include "partition.h"
#include <bits/stdc++.h>
#define f first
#define s second
#define pb push_back
#define mp make_pair
#define ll long long
using namespace std;
const ll N=2e6;
std::vector<int> solve(std::vector<int> A) {
    vector <int> ans;
	ans.clear();
    pair <int,int> p[N+5];
    ll n=A.size();
    for (int i=0; i<A.size(); i++){
    	p[i]=make_pair(A[i],i);
	}
	sort(p,p+n);
	
	for (int i=0; i<n; i+=2) ans.pb(p[i].s);
	for (int i=1; i<n; i+=2) ans.pb(p[i].s); return ans;
}
