#include <bits/stdc++.h>
using namespace std;
long long int q;
long long int gcd(long long int a, long long int b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
int main() {
  ios_base::sync_with_stdio(false);
  ;
  cin >> q;
  bool primo = true;
  std::vector<long long int> v;
  for (long long int i = 2; i * i <= q; i++) {
    if (q % i == 0) {
      primo = false;
      break;
    }
  }
  if (primo) {
    cout << "1" << endl << "0" << endl;
    return 0;
  }
  long long int aux = q;
  long long int cont = 2;
  while (aux != 1) {
    long long int primogran = cont;
    if (primogran * primogran > aux) {
      v.push_back(aux);
      break;
    }
    while (aux % cont == 0) {
      v.push_back(cont);
      aux /= cont;
    }
    cont++;
  }
  if (v.size() == 2) {
    cout << 2 << endl;
    return 0;
  }
  long long int resp = 1;
  for (int i = 0; i < v.size() - 2; i++) {
    resp *= v[i];
  }
  cout << "1" << endl;
  cout << q / resp << endl;
}
