#include <bits/stdc++.h>
using namespace std;
const long long mod = 1e9 + 7;
const int INF = 1e9 + 7;
const long double eps = 1e-9;
const int maxn = 100;
bool track[maxn][maxn];
int main() {
  long long n;
  cin >> n;
  set<long long> iset;
  long long m = n;
  for (long long i = 2; i * i <= m; i++) {
    if (m % i) continue;
    while (m % i == 0) {
      m /= i;
    }
    iset.insert(i);
  }
  if (m > 1) iset.insert(m);
  if (iset.empty()) {
    puts("1");
    puts("0");
    return 0;
  }
  if ((int)(iset.size()) == 1) {
    long long aa = *(iset.begin());
    if (n == aa * aa) {
      puts("2");
    } else if ((n % (aa * aa)) == 0) {
      puts("1");
      cout << aa * aa << "\n";
    } else {
      puts("1");
      puts("0");
    }
    return 0;
  }
  if ((int)(iset.size()) == 2) {
    long long aa = *(iset.begin());
    iset.erase(*iset.begin());
    long long bb = *(iset.begin());
    if (n % (aa * aa) == 0) {
      puts("1");
      cout << aa * aa << "\n";
    } else if (n % (bb * bb) == 0) {
      puts("1");
      cout << bb * bb << "\n";
    } else
      puts("2");
    return 0;
  }
  if ((int)(iset.size()) > 2) {
    puts("1");
    long long aa = *(iset.begin());
    iset.erase(*iset.begin());
    long long bb = *(iset.begin());
    cout << aa * bb << "\n";
  }
  return 0;
}
