#include<stdio.h>
#include<string.h>
int main()
{
    int i,left,tmp;
    int w[10];
    int first;
    while (scanf("%d", &left) != EOF) {
        memset(w,0,sizeof(w));
        for (i=9;i>=0;i--) {
            tmp = 1<<i;
            if (left>=tmp) {
                w[i]=1;
                left-=tmp;
            }
        }
        first = 1;
        for (i=0;i<10;i++) {
            if (w[i]) {
                if (first) printf("%d", 1<<i);
                else       printf(" %d",1<<i);
                first = 0;
            }
        }
        printf("\n");
    }
    return 0;
}