#include <bits/stdc++.h>
using namespace std;
vector<int64_t> prime(int64_t p) {
  vector<int64_t> v;
  while (p % 2 == 0) {
    p /= 2;
    v.push_back(2);
  }
  for (int64_t i = 3; i * i <= p; i += 2) {
    while (p % i == 0) {
      p /= i;
      v.push_back(i);
    }
  }
  if (p > 2) {
    v.push_back(p);
  }
  return v;
}
int main() {
  int64_t n;
  cin >> n;
  vector<int64_t> v = prime(n);
  if (n == 1 || v.size() == 1) {
    cout << 1 << "\n" << 0;
  } else if (v.size() == 2) {
    cout << 2;
  } else {
    cout << 1 << "\n" << v[0] * v[1];
  }
}
