#include <bits/stdc++.h>
using namespace std;
int max_num = 1e5;
int ccnt = 0;
long long son[10000 + 5];
vector<long long> p[10000 + 5];
void put(long long n, long long k) {
  if (ccnt >= max_num) return;
  if (k == 0 || n == 0) {
    cout << son[n] << ' ';
    ccnt++;
    return;
  }
  for (auto it : p[n]) put(it, k - 1);
  return;
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long x, k;
  cin >> x >> k;
  long long sqrtx = sqrt(x);
  int cnt = 0;
  for (long long i = 1; i <= sqrtx; i++) {
    if (x % i == 0) {
      son[cnt++] = i;
      if (x / i != i) son[cnt++] = x / i;
    }
  };
  sort(son, son + cnt);
  for (int i = 0; i < cnt; i++)
    for (int j = i; j < cnt; j++)
      if (son[j] % son[i] == 0) p[j].push_back(i);
  put(cnt - 1, k);
  return 0;
}
