#include <bits/stdc++.h>
using namespace std;
long long x, k, cnt, t;
long long a[1000005];
void dfs(long long x, long long tot) {
  if (tot > k || x == 1) {
    printf("%lld ", x);
    t++;
    return;
  }
  for (long long i = 1; a[i] <= x && i <= cnt; i++) {
    if (t >= 100000) return;
    if (x % a[i] == 0) dfs(a[i], tot + 1);
  }
}
signed main() {
  scanf("%lld %lld", &x, &k);
  if (x > 1 && k > 100000) {
    for (long long i = 1; i <= 100000; i++) printf("1 ");
    return 0;
  }
  for (long long i = 1; i <= x / i; i++) {
    if (x % i == 0) {
      a[++cnt] = i;
      if (x / i != i) a[++cnt] = x / i;
    }
  }
  sort(a + 1, a + cnt + 1);
  dfs(x, 1);
  puts("");
  return 0;
}
