#include <bits/stdc++.h>
using namespace std;
int main(void) {
  long long int num, num_backup;
  long long int a[2], j = 0;
  cin >> num;
  num_backup = num;
  for (long long int i = 2; i * i <= num; i++) {
    if (num % i == 0) {
      a[j++] = i;
      if (j == 2) break;
      num /= i;
      i--;
    }
  }
  if (j == 0)
    cout << 1 << endl << 0 << endl;
  else if (a[0] * a[1] == num_backup || j == 1)
    cout << 2 << endl;
  else
    cout << 1 << endl << a[0] * a[1] << endl;
  return 0;
}
