#include <bits/stdc++.h>

using namespace std;

int main(){
    ios_base::sync_with_stdio(false);
    cin.tie(0); cout.tie(0);
    int n, n2, x, z=0;
    cin>>n;
    vector <int> veki1 = {0};
    vector <int> veki2 = {0};

    for(int i=1; i<=n-2; i++){
        if(i==n-2 and n%2==1){
            veki2.push_back(2*n-i+1);
            veki1.push_back(i);
        }
        else if(i%2==1){
            veki1.push_back(2*n-i+1);
            veki1.push_back(i);
        }
        else if(i%2==0){
            veki2.push_back(2*n-i+1);
            veki2.push_back(i);
        }

    }
    veki1[0]=n-1;
    veki1.push_back(n+1);
    veki2[0]=n;
    veki2.push_back(n+2);

//    int i=0;
    for(int el: veki1){
        cout<<el<<" ";
//        z+=abs(i-el);
//        i=el;
        }

    cout<<endl;
//    i=0;
    for(int el: veki2){
        cout<<el<<" ";
//        z+=abs(i-el);
//        i=el;
        }
    cout<<endl;

//    cout<<z<<endl;
}