#include <bits/stdc++.h>
using namespace std;
int main() {
  set<long long> s;
  long long n;
  cin >> n;
  for (long long x = 1; x * x <= n; ++x) {
    if (n % x == 0) s.insert(x), s.insert(n / x);
  }
  vector<long long> v;
  v.push_back(1);
  for (auto x : s) {
    if (x % v.back() == 0) v.push_back(x);
  }
  sort(v.begin(), v.end());
  reverse(v.begin(), v.end());
  v.pop_back();
  for (auto x : v) cout << x << " ";
  cout << endl;
  return 0;
}
