#include <bits/stdc++.h>
using namespace std;
long long N, tot, u, x;
int main() {
  cin >> N;
  x = N;
  for (long long i = 2; i * i <= N; ++i)
    for (; N % i == 0; N /= i, ++tot)
      if (!u)
        u = i;
      else
        x = i;
  if (N > 1) ++tot;
  if (tot == 2) return printf("2\n") & 0;
  if (tot == 1) return printf("1\n0\n") & 0;
  printf("1\n%I64d\n", x * u);
  return 0;
}
