#include <iostream> using namespace std; typedef long long ll; int main(){ ll n; cin >> n; while(n){ cout << n << " "; n >>= 1; } return 0; }