#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int n;
  cin >> n;
  int m = n;
  int b = 1;
  int p = 1;
  while (n > 1) {
    if ((b + p) % m == 0) {
      cout << m << " ";
    } else {
      cout << (b + p) % m << " ";
    }
    b = b + p;
    p++;
    n--;
  }
}
