#include <bits/stdc++.h>
using namespace std;
vector<int> ans;
int n;
int vis[100005];
void DFS(int x) {
  if (vis[x]) return;
  vis[x] = true;
  DFS((x * 2) % n);
  DFS((x * 2 + 1) % n);
  ans.push_back(x);
}
int main() {
  cin >> n;
  if (n & 1)
    printf("-1\n");
  else {
    DFS(0);
    for (int i = ans.size() - 1; i >= 0; i--) {
      printf("%d ", ans[i]);
    }
    cout << 0 << endl;
  }
  return 0;
}
