#include<iostream>

int main()
{
	int a;
	while( std::cin >> a ){
		int i = 0;
		while( a > 0 ){
			if( a & 1 ) std::cout << ( 1 << i ) << ( ( a >> 1 ) & -( a >> 1 ) ? " " : "" );
			a >>= 1;
			i++;
		}
		
		std::cout << std::endl;
	}

 	return 0;
}