#include <bits/stdc++.h>
using namespace std;
char buf[1 << 15], *fs, *ft;
inline char getc() {
  return (fs == ft &&
          (ft = (fs = buf) + fread(buf, 1, 1 << 15, stdin), fs == ft))
             ? 0
             : *fs++;
}
inline int read() {
  register int x = 0, f = 1;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  return x * f;
}
const int MAXN = 500010;
int n, top;
int v[MAXN], p[MAXN], w[MAXN];
inline void prepare() {
  w[1] = 1;
  for (register int i = 2; i <= n; ++i) {
    if (!v[i]) p[++top] = v[i] = i, w[i] = 1;
    for (register int j = 1; j <= top; ++j) {
      if (n / i < p[j]) break;
      int ww = i * p[j];
      v[ww] = p[j];
      w[ww] = i;
      if (p[j] == v[i]) break;
    }
  }
}
int main() {
  n = read();
  prepare();
  sort(w + 1, w + 1 + n);
  for (register int i = 2; i <= n; ++i) printf("%d ", w[i]);
  return 0;
}
