// inputに入力データ全体が入る
function Main(input) {
  n = parseInt(input);
  var priArray = getPrimeFactors(n);
  var summary = [];
  var tmp = 0 ;
  for (let i=0;i<priArray.length;i++){
    if (priArray[i] == tmp){
      summary[summary.length - 1] ++;
    }else{
      summary.push(1);
      tmp = priArray[i];
    }
  }
  var sum = 0
  for (let i=0;i<summary.length;i++){
    var ok = 1;
    var cnt = 1;
    while (ok === 1){
      if (cnt * (cnt+1) / 2 > summary[i]){
        ok = 0;
        sum += cnt -1;
      }else{
        cnt ++;
      }
    }
  }
  console.log(sum);
}
  
const getPrimeFactors = n => {
  if (n < 2) return [];
  if (n === 2 || n === 3 || n === 5) return [n];
  if (n % 2 === 0) return [2, ...getPrimeFactors(n/2)];
  if (n % 3 === 0) return [3, ...getPrimeFactors(n/3)];
  if (n % 5 === 0) return [5, ...getPrimeFactors(n/5)];
  let prime = 7;
  let step = 4;
  const limit = Math.sqrt(n);
  while (prime <= limit) {
    if (n % prime === 0) return [prime, ...getPrimeFactors(n/prime)];
    prime += step;
    step = 6 - step;
  }
  return [n];
}

Main(require("fs").readFileSync("/dev/stdin","utf8"));
