#include <bits/stdc++.h>
using namespace std;
long long limit = 4294967296;
int MOD = 1000000007;
template <typename T>
void print(const T& x) {
  cerr << x << ' ';
}
template <typename T1, typename... T2>
void print(const T1& first, const T2&... anst) {
  print(first);
  print(anst...);
}
long long gcd(long long a, long long b) { return (b == 0 ? a : gcd(b, a % b)); }
long long lcm(long long a, long long b) { return (a * (b / gcd(a, b))); }
vector<long long> factorization(long long n) {
  vector<long long> primes;
  while (n % 2 == 0) {
    primes.push_back(2);
    n /= 2;
  }
  for (long long i = 3; i * i <= n; i += 2) {
    while (n % i == 0) {
      primes.push_back(i);
      n /= i;
    }
  }
  if (n > 1) primes.push_back(n);
  return primes;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  ;
  long long n;
  cin >> n;
  vector<long long> factors = factorization(n);
  if (factors.size() <= 1)
    cout << 1 << endl << 0 << endl;
  else if (factors.size() == 2)
    cout << 2 << endl;
  else {
    cout << 1 << endl;
    cout << factors[0] * factors[1] << endl;
  }
  return 0;
}
