#include <bits/stdc++.h>
bool a[6000000] = {false};
int b[6000000];
int c[6000000] = {0};
using namespace std;
int main() {
  long long n;
  cin >> n;
  for (int i = 2; i < 3000000; i++) {
    if (!a[i]) {
      for (int j = 2 * i; j < 6000000; j += i) {
        a[j] = true;
      }
    }
  }
  int k = 0, x;
  for (long long i = 2; i * i <= n; i++) {
    long long u = n;
    if (!a[i] && n % i == 0) {
      b[k] = i;
      while (u > 0 && u % i == 0) {
        c[k]++;
        u /= i;
      }
      k++;
    }
  }
  if (k == 0)
    cout << 1 << endl << 0 << endl;
  else if (k == 1) {
    if (c[0] > 2)
      cout << 1 << endl << (long long)b[0] * b[0] << endl;
    else if (c[0] == 2 && (long long)b[0] * b[0] != n)
      cout << 1 << endl << (long long)b[0] * b[0] << endl;
    else
      cout << 2 << endl;
  } else
    cout << 1 << endl << (long long)b[0] * b[1] << endl;
  return 0;
}
