#include <iostream>

int main()
{
    int w;
    while (std::cin >> w) {
        bool top = true;
        for (int i = 1; i <= 512; i <<= 1) {
            if (w & i) {
                if (top) top = false;
                else std::cout << " ";
                std::cout << (w & i);
            }
        }
        std::cout << std::endl;
    }
}