#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 0, j = 2; i < n - 1; i++, j += 1 + i)
    if (j % n != 0)
      printf("%d ", j % n);
    else
      printf("%d ", n);
}
