#include <bits/stdc++.h>
using namespace std;
int main(void) {
  long long q;
  cin >> q;
  if (q == 1) {
    cout << 1 << endl;
    cout << 0 << endl;
    return 0;
  }
  vector<long long> w;
  long long q0 = q;
  for (long long a = 2; a * a <= q && w.size() <= 5; a++) {
    while (q % a == 0) {
      w.push_back(a);
      q /= a;
    }
  }
  if (q > 1) w.push_back(q);
  if (w.size() == 2) {
    cout << 2 << endl;
    return 0;
  } else if (w.size() < 2) {
    cout << 1 << endl;
    cout << 0 << endl;
    return 0;
  } else {
    cout << 1 << endl;
    cout << (w[0] * w[1]) << endl;
    return 0;
  }
}
