#include <bits/stdc++.h>
using namespace std;
#define ll long long

vector<int> solve(vector<int> A){
    ll n;
    n=A.size();
    vector<int>ANS;
    ll s=0;
    for(int i=0;i<(n/2)-1;i++){
        ANS.push_back(i);
    }
    ANS.push_back(n-1);
    for(int i=(n/2)-1;i<n-1;i++){
        ANS.push_back(i);
    }
    return ANS;
    /*vector<pair<int,int>>l;
    for(int i=0;i<n;i++){
        s+=A[i];
        l.push_back({A[i],i});
    }
    sort(l.begin(),l.end());
    ll m=(n+1)/2;
    ll cnt=0;
    for(int i=0;i<m;i++){
        cnt+=l[i].first;
    }
    int k=0;
    while(2*cnt<s){
        k++;
        cnt-=l[m-k].first;
        cnt+=l[n-k].first;
    }
    pair<int,int>sp;
    if(k==0){
        sp=l[m-1];
    }else{
        sp=l[n-k];
    }
    vector<pair<int,int>>pr;
    vector<pair<int,int>>sf;
    for (int i=0;i<m-k;i++){
        if(k==0&&i==m-1)continue;
        pr.push_back(l[i]);
    }
    for(int i=n-k+1;i<n;i++){
        pr.push_back(l[i]);
    }
    for(int i=m-k;i<n-k;i++){
        sf.push_back(l[i]);
    }

    for(auto x:pr){
        ANS.push_back(x.second);
    }
    ANS.push_back(sp.second);
    for(auto x:sf){
        ANS.push_back(x.second);
    }
    return ANS;*/

}