#include<iostream>
#include<stdio.h>

using namespace std;

int main(){

    int x =0;
    cin >> x;
    int counter = 0 ;

        int m = 2;
        for(int i=2 ; i<10 ; ++i){
             i = m;
            if(x==1)break;
            if(i==9 && x % i !=0){
                counter++;
                break;
            }
            if(x % i != 0){
                m++;
                continue;
            }else{
                x = x / i;
                counter++;
                m = i;
            }
        }
    
    

    cout << counter + 1 ;

    return 0;
}