#include<bits/stdc++.h>
using namespace std;
int main() {
    int n;
    cin>>n;
    vector <int> v;
    vector <int> np;
    vector <int> p;
    vector <int> kraj;
    if (n%2==0) {
    for (int i=2*n; i>n; i--) {
        v.push_back(i);
    }
    v.push_back(n);
    for (int i=1; i<=n; i++) {
        if (i%2==0) {
            p.push_back(i);
        }
        else {
            np.push_back(i);
        }
    }
    int pi=0;
    int npi=0;
    int iv=0;
    int b=0;
    while (b<n) {
        if (b%2==0) {
            cout<<v[iv]<<" ";
            iv++;
        }
        else {
            cout<<np[npi]<<" ";
            npi++;
        }
        b++;
    }
    cout<<endl;
    b--;
    while (b<n*2-1) {
        if (b%2==0) {
            cout<<v[iv]<<" ";
            iv++;
        }
        else {
            cout<<p[pi]<<" ";
            pi++;
        }
        b++;
    }
    }
    else {
        for (int i=2*n; i>n; i--) {
        if (i<n+4) {
            kraj.push_back(i);
        }
        else {
            v.push_back(i);
        }
    }
    kraj.push_back(n);
    for (int i=1; i<=n; i++) {
        if (i%2==0) {
            p.push_back(i);
        }
        else {
            np.push_back(i);
        }
    }
    int pi=0;
    int npi=0;
    int iv=0;
    int ikraj=0;
    int b=0;
    while (b<n) {
        if (b%2==0 && b!=0 && b!=n-1) {
            cout<<v[iv]<<" ";
            iv++;
        }
        else if (b==0 || b==n-1) {
            cout<<kraj[ikraj]<<" ";
            ikraj++;
        }
        else {
            cout<<np[npi]<<" ";
            npi++;
        }
        b++;
    }
    cout<<endl;
    b--;
    while (b<n*2-1) {
        if (b%2==0 && b!=n-1 && b!=2*n-2) {
            cout<<v[iv]<<" ";
            iv++;
        }
        else if (b==n-1 || b==2*n-2) {
            cout<<kraj[ikraj]<<" ";
            ikraj++;
        }
        else {
            cout<<p[pi]<<" ";
            pi++;
        }
        b++;
    }
    }
}