#include <bits/stdc++.h>
using namespace std;
int a[20000];
int b[22];
int aa(int x) {
  int flag = 1;
  if (x < 2) flag = 0;
  for (int i = 2; i * i <= x; i++) {
    if (x % i == 0) flag = 0;
  }
  return flag;
}
int main() {
  int u = 0;
  for (int i = 1; i <= 100000; i++) {
    if (aa(i)) a[u++] = i;
  }
  int n, k;
  scanf("%d%d", &n, &k);
  if (k == 1) {
    printf("%d\n", n);
    return 0;
  }
  int o = 1;
  int p = 0;
  while (o) {
    o = 0;
    for (int i = 0; a[i] <= n; i++) {
      if (n % a[i] == 0) {
        b[p++] = a[i];
        n = n / a[i];
        o = 1;
        break;
      }
    }
    if (p == k - 1) break;
  }
  if (p != k - 1 || n == 1)
    printf("-1\n");
  else {
    for (int i = 0; i < p; i++) printf("%d ", b[i]);
    printf("%d\n", n);
  }
}
