#include <bits/stdc++.h>
using namespace std;
int n;
void setup() {
  cin >> n;
  int lastX = 1, remain = n;
  while (remain > 1) {
    int best = 0, bestX;
    for (int x = lastX * 2; x <= n; x += lastX) {
      int cnt = n / x;
      if (cnt > best || (cnt == best && x > bestX)) {
        best = cnt;
        bestX = x;
      }
    }
    for (int x = lastX; x <= n; x += lastX)
      if (x % bestX != 0) {
        remain--;
        cout << lastX << ' ';
      }
    lastX = bestX;
  }
  cout << lastX;
}
void xuly() {}
int main() {
  iostream::sync_with_stdio(0);
  cin.tie(NULL);
  cout.tie(NULL);
  setup();
  xuly();
  return 0;
}
