#include<bits/stdc++.h> using namespace std; int main(){ int n; cin>>n; for(int i=2;i<=n;i++){ while(n%i==0){ cout<<i<<" "; n=n/i; } } } /************************************************************** Problem: 1234 User: fandaohan Language: C++ Result: Accepted Time:5 ms Memory:2072 kb ****************************************************************/