#include<iostream>
#include<cmath>
using namespace std;
int n;
bool a[100001];
void b(){
if(n%2==1){
cout<<"-1";
return;
}
int temp=n;
for(int i=500;temp!=0;i--){
if(temp%2==0&&temp>=pow(2,i)){
a[i]=1;
}
else{
a[i]=0;
}
temp-=pow(2,i);
}
for(int i=500;i>=1;i--){
if(a[i]){
cout<<pow(2,i)<<" ";
}
}
}
int main(){
cin>>n;
b();
return 0;
}