#include <iostream>
using namespace std;

int main() {
  int w;
  while(cin >> w) {
    for(int i = 0, cnt = 0; w; ++i) {
      if(w & (1<<i)) {
	if(cnt) cout << " ";
	++cnt;
	cout << (1<<i);
	w &= ~(1<<i);
      }
    }
    cout << endl;
  }
  return 0;
}