#include #include #include using namespace std; using namespace atcoder; using mint = modint998244353; #define rep(i,n) for (int i = 0; i < (n); ++i) #define Inf32 1000000001 #define Inf64 4000000000000000001 bool F[100001]; int main(){ vector ps; for(int i=2;i<=100000;i++){ if(F[i]==true)continue; ps.push_back(i); for(int j=i;j<=100000;j+=i)F[j] = true; } int l = 0,r = ps.size()-1; int M; cin>>M; vector ans; while(M!=0){ int t = 1; int cnt = 0; while(t*2-1<=M){ t*=2; cnt++; } M -= t - 1; int P = ps[l]; int Cur = 1; rep(j,cnt){ if(Cur * P <= 100000){ Cur *= P; ans.push_back(Cur); continue; } while(P*ps[r]>100000)r--; ans.push_back(P*ps[r]); int tt = P*ps[r]; while(j!=cnt-1 && tt*P<=100000){ tt *= P; ans.push_back(tt); j++; } r--; } l++; } cout<