#include<bits/stdc++.h>

using namespace std;

signed main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  int n;
  cin >> n;
  int ll = 1, lu = n, rl = n + 1, ru = 2 * n;
  vector<int> va, vb;
  for (int i = 0; i < n; i++) {
    if (i == 0) {
      va.push_back(lu--);
      continue;
    }
    if (i == n - 1 and i % 2 == 0) {
      va.push_back(lu--);
      continue;
    }
    if (i == n - 1 and i % 2 == 1) {
      va.push_back(rl++);
      continue;
    }
    if (i % 2 == 0)
      va.push_back(ll++);
    else
      va.push_back(ru--);
  }
  for (int i = 0; i < n; i++) {
    if (i == 0 and n % 2 == 0) {
      vb.push_back(lu--);
      continue;
    }
    if (i == 0 and n % 2 == 1) {
      vb.push_back(rl++);
      continue;
    }
    if (i % 2 == n % 2)
      vb.push_back(ll++);
    else
      vb.push_back(ru--);
  }
  for (int x : va)
    cout << x << " ";
  cout << "\n";
  for (int x : vb)
    cout << x << " ";
  return 0;
}