import std.stdio;
import std.conv;
import std.string;

void main(){
    
    while(true){

	auto s = readln();
	if(stdin.eof()) break;
	int n = to!int(chomp(s));
	int m = 1;
	while(n > 0){
	    if(n % 2 == 1){
	       	writef("%d",m);
		n /= 2;
		if(n <= 0) break;
		writef(" ");
	    }else {
		n /= 2;
	    }
	    m *= 2;
	    }
	writeln("");
    }
}