#include <bits/stdc++.h>
using namespace std;
int X1, Y1, X2, Y2;
int a, b;
int main() {
  long long int n, k, kk;
  cin >> n >> k;
  kk = k;
  vector<long long int> v(n + 1, 0);
  vector<long long int> b;
  v[0] = 1;
  v[1] = 1;
  for (long long int i = 2; i <= n; i++) {
    if (v[i] == 0) {
      b.push_back(i);
      for (long long int j = 1; j * i <= n; j++) {
        v[i * j] = 1;
      }
    }
  }
  k--;
  vector<long long int> c;
  while (k) {
    for (long long int i = 0; i < b.size() && k && n != 1; i++) {
      while (n % b[i] == 0 && k && n != 1) {
        c.push_back(b[i]);
        n = n / b[i];
        k--;
      }
    }
    if (n == 1) break;
  }
  if (n != 1) c.push_back(n);
  if (k > 0) {
    cout << -1;
    return 0;
  }
  if (c.size() != kk) {
    cout << -1;
    return 0;
  }
  for (long long int i = 0; i < c.size(); i++) {
    cout << c[i] << " ";
  }
}
