#include <bits/stdc++.h>
using namespace std;
vector<long long> lol[500005];
long long vis[500005];
vector<long long> p;
long long done[500005];
vector<long long> ans;
long long arr[500005];
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  for (long long i = 2; i < 500005; i++) {
    if (!vis[i]) {
      p.push_back(i);
      for (long long j = i * i; j < 500005; j += i)
        if (!vis[j]) vis[j] = i;
    }
  }
  long long n;
  cin >> n;
  done[1] = 1;
  long long cur = 1;
  for (int i = 0; p[i] <= n && i < p.size(); i++, cur++) {
    done[p[i]] = 1;
    cout << 1 << " ";
  }
  vector<long long> ans;
  long long val = 1;
  long long g = 2;
  for (int i = cur; i <= n; i++) {
    long long vv = 0;
    for (long long j = g; j <= g + 3; j++) {
      for (long long l = j; l <= n; l += j) {
        if (!done[l]) {
          if (done[l / vis[l]]) {
            if (l / vis[l] > g + 1) continue;
            g = l / vis[l];
            ans.push_back(g);
            done[l] = 1;
            vv = 1;
            break;
          }
        }
      }
      if (vv) break;
    }
  }
  sort(ans.begin(), ans.end());
  for (long long x : ans) cout << x << " ";
  return 0;
}
