#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
const double PI = acos(-1.0);
int main() {
  ios_base::sync_with_stdio(false);
  long long q;
  cin >> q;
  vector<long long> divisores;
  for (long long i = 2; i * i <= q; i++) {
    while (q % i == 0) {
      divisores.push_back(i);
      q /= i;
    }
  }
  if (q != 1) divisores.push_back(q);
  if (divisores.size() == 2)
    cout << "2" << endl;
  else {
    cout << "1" << endl;
    if (divisores.size() <= 1)
      cout << "0" << endl;
    else
      cout << (divisores[0] * divisores[1]) << endl;
  }
  return 0;
}
