#include <bits/stdc++.h>
using namespace std;
int isp[10000010];
int p[900000];
int prime() {
  int i, j;
  isp[1] = 0;
  for (i = 2; i <= 10000000; i++) isp[i] = -1;
  for (i = 2; i <= 10000000; i++) {
    if (isp[i] == -1) {
      isp[i] = 1;
      for (j = 2; j * i <= 10000000; j++) isp[i * j] = 0;
    }
  }
  int q = 0;
  for (i = 1; i <= 10000000; i++)
    if (isp[i]) p[++q] = i;
  return q;
}
vector<long long> L;
int main() {
  int noip = prime();
  long long n, nn, i;
  while (cin >> n) {
    L.clear();
    nn = n;
    for (i = 1; i <= noip; i++) {
      while (nn % p[i] == 0) {
        nn /= p[i];
        L.push_back(p[i]);
      }
    }
    if (nn != 1) L.push_back(nn);
    if (n == 1) L.push_back(1);
    if (L.size() == 1) cout << 1 << endl << 0 << endl;
    if (L.size() == 2) cout << 2 << endl;
    if (L.size() > 2) cout << 1 << endl << L[0] * L[1] << endl;
  }
  return 0;
}
