#include<bits/stdc++.h>
using namespace std;
#define ll long long
#define pb push_back
#define mem(x,y) memset(x,y,sizeof(x))

vector<pair<ll,ll>>vc;
ll visi[200005], ans[200005];

int main()
{
    int test;
    //cin>>test;
    //while(test--)
    {
        ll i,j,k,s,d,r,m,n,f;
        cin>>n;

        for(i=1; i<=n; i++)
        {
            ll x,y;
            cin>>x>>y;
            vc.pb({x,y});
        }

        ans[1] = 1;
        visi[0] = 1;
        pair<ll,ll> last = vc[0];

        for(i=2; i<=n; i++)
        {
            m =-1;
            for(j=0; j<n; j++)
            {
                if(visi[j]) continue;

                d = (last.first-vc[j].first)*(last.first-vc[j].first) + (last.second-vc[j].second)*(last.second-vc[j].second);
                //d = sqrt(d);
                if(d>m) m = d, r = j;
            }

            ans[i] = r+1;
            visi[r] = 1;
            last = vc[r];
        }

        for(i=1; i<=n; i++) cout<<ans[i]<<" ";
    }
}

