#include <iostream>
#include <sstream>
#include <string>
#include <vector>
#include <stack>
#include <queue>
#include <deque>
#include <set>
#include <map>
#include <algorithm>
#include <functional>
#include <numeric>
#include <utility>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <cmath>
#include <ctime>
using namespace std;

typedef long long ll;
typedef pair<int, int> P;

#define all(c) (c).begin(), (c).end()
#define pb push_back
#define mp make_pair
#define EXIST(v,i) (find(all(v), i) != (v).end())
#define ERASE(v,i) (v).erase(remove(all(v), i), (v).end())
#define INDEX(v,i) (find(all(v), i) - (v).begin())
#define rep(i,n) for(int i = 0; i < (int)n; ++i)
#define debug(x) cerr << #x << " = " << (x) << endl;

inline int toInt(string s) {int v; istringstream sin(s);sin>>v;return v;}
template<class T> inline string toString(T x) {ostringstream sout;sout<<x;return sout.str();}

const int INF = 100000000;
const double PI = 3.14159265358979323846;
const double EPS = 1e-10;

int weight[10] = {1, 1<<1, 1<<2, 1<<3, 1<<4, 1<<5, 1<<6, 1<<7, 1<<8, 1<<9};

int main() {
	sort(weight, weight + 10);
#if 0
	rep(i,10) cout << weight[i] << endl;
#endif
	for(int W; cin >> W;) {
		vector<int> ans;
		while(W) {
			int add = *(upper_bound(weight, weight + 10, W) - 1);
			//cout << add << W << endl;
			ans.pb(add);
			W -= add;
		}
		sort(all(ans));
		cout << ans[0];
		for(int i = 1, n = ans.size(); i < n; i++) {
			cout << " " << ans[i];
		}
		cout << endl;
	}
	return 0;
}