#include <bits/stdc++.h>
using namespace std;
using namespace std;
int n, ans[111111];
bool flag[111111];
int main() {
  cin >> n;
  if (n % 2) {
    cout << "-1" << endl;
    return 0;
  }
  int now = 0;
  for (int c = 0; c < n; c++) {
    if (now % 2 == 0) now += 1;
    int u = (now - 1 + n) / 2;
    int v = u + n / 2;
    u %= n;
    v %= n;
    if (u > v) swap(u, v);
    if (flag[v] == false) {
      ans[c] = v;
      flag[v] = true;
      now = v;
    } else {
      ans[c] = u;
      flag[u] = true;
      now = u;
    }
  }
  for (int c = n - 1; c >= 0; c--) cout << ans[c] << endl;
  cout << 0 << endl;
  return 0;
}
