#include <bits/stdc++.h>
using namespace std;
const int N = 500010;
int n;
bool not_pri[N];
int phi[N], mu[N];
vector<int> pri;
int cnt[N];
void euler_sieve(int lim) {
  mu[1] = 1;
  for (int i = 2; i <= lim; i++) {
    if (!not_pri[i]) {
      pri.push_back(i);
      phi[i] = i - 1;
      mu[i] = -1;
    }
    for (int t = 0; t < (int)pri.size(); t++) {
      int j = pri[t];
      if ((int)i * j > lim) break;
      not_pri[i * j] = true;
      if (i % j == 0) {
        phi[i * j] = phi[i] * j;
        mu[i * j] = 0;
        break;
      }
      phi[i * j] = phi[i] * (j - 1);
      mu[i * j] = -mu[i];
    }
  }
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cin >> n;
  euler_sieve(n);
  for (int i = 1; i <= n; i++) {
    if (i == 1 || !not_pri[i])
      cnt[1]++;
    else {
      for (int k : pri) {
        if (i % k == 0) {
          cnt[i / k]++;
          break;
        }
      }
    }
  }
  cnt[1]--;
  for (int i = 1; cnt[i]; i++) {
    for (int j = 1; j <= cnt[i]; j++) {
      cout << i << ' ';
    }
  }
  getchar();
  getchar();
  return 0;
}
