#include <iostream>
#include <vector>
#include <algorithm>
#include <iterator>
#include <cstdint>

int main()
{
	std::uint16_t weight_of_obj;
	while (std::cin >> weight_of_obj) {
		std::vector<std::uint16_t> weights;
		std::uint16_t weight = 1;
		while (weight_of_obj != 0) {
			if ((weight_of_obj & 1) == 1) {
				weights.push_back(weight);
			}
			weight_of_obj >>= 1;
			weight *= 2;
		}
		std::copy(weights.begin(), weights.end() - 1,
				std::ostream_iterator<std::uint16_t>(std::cout, " "));
		std::cout << weights.back() << std::endl;
	}

	return 0;
}