//#pragma comment(linker, "/stack:200000000")
//#pragma GCC optimize("Ofast", "unroll-loops")
//#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,avx2,fma")


#include <bits/stdc++.h>
using namespace std;

#define fast() ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL);


using lli = long long int;
using ld = long double;
using ull = unsigned long long int;


#define FOR(i,x,n) for(lli i=x;i<n;i++)
#define RFOR(i,x,n) for(lli i=x;i>=n;i--)
#define pb push_back
#define Resize(c) c.resize(distance(c.begin(),unique(c.begin(),c.end())))
#define unique_sort(c) (sort(c.begin(),c.end()), Resize(c))
#define mem(x,y) memset(x,y,sizeof(x))
#define all(x) (x).begin(), (x).end()
#define sz(x) (lli)x.size()
#define fs first
#define ss second
#define mp make_pair
#define lb '\n'
#define gc getchar()
#define pc putchar
#define il inline void
#define debug(x) cerr<<#x<<" = "<<(x)<<endl;
 
 
const lli mod=1e9+7;

template <typename T, typename U, typename V> using TP = tuple<T,U,V>;
template <typename T> using VI = vector<T>;
template <typename T> using LI = list<T>;
template <typename T, typename U> using PI = pair<T,U>;
template <typename T, typename U> using VPI = vector<pair<T,U>>;
template <typename T> using PQ = priority_queue<T>;

template <typename T> inline void read(T& r){ static char c; r=0; int f=1; for(c=gc; c<'0'||c>'9'; c=gc) if(c=='-')f=-1; for(; c>='0'&&c<='9'; r=(r<<1)+(r<<3)+(c^48),c=gc); r*=f; } 
template <typename T, typename... Args> inline void read(T& r, Args&... args) { read(r); read(args...); }

template <typename T> inline void rdstr(T& x){static char c;  for(c=gc; (c!=10 && c!=' ') ; c=gc)x.pb(c);}
template <typename T1, typename T2> inline void chkmin(T1 &a, const T2 & b) {if (a > b) a = b;}
template <typename T1, typename T2> inline void chkmax(T1 &a, const T2 & b) {if (a < b) a = b;}


unordered_set<lli> myset;

lli power(lli x, lli y)
{
    lli res = 1;    
   
    while (y > 0)
    {
        if (y & 1) res = (res*x)%mod;
 
        y = y>>1;
        x = (x*x)%mod;  
    }
    return res;
}



lli pF(lli n)  
{  
    lli cnt=0;
    while (n % 2 == 0)  
    { 
        cnt+=1; 
        lli tpelem = power(2,cnt);
        if(myset.find(tpelem)==myset.end()){myset.insert(tpelem); return tpelem;}    
        n = n/2;  
    }  
  
    for (lli i = 3; i*i<= n; i = i + 2)  
    {  
        lli cn = 0;
        while (n % i == 0)  
        {  
            cn+=1;
            lli tppow = power(i,cn);
            if(myset.find(tppow)==myset.end()){myset.insert(tppow); return tppow;}    
            n = n/i;  
        }  
    }  
    return (n>2 && myset.find(n)==myset.end())?n: 1;
}  


bool checkprime(lli n)
{
    lli fac=0;
    for(lli i=2; i*i<=n; i++)if(n%i==0){fac++; break;}
    return (fac==0)?true: false;
}


void solve()
{
	lli n; read(n);
	if(n==1){cout<<0<<lb;}
	else
	{
	    lli ans = 0;
	    while(n>1)
	    {
	        if(checkprime(n)){ans+=1; break;}
	        else
	        {
	            lli tp = pF(n);
	            n = n/tp;
	            
	            //cout<<tp<<" "<<n<<lb;
	            if(tp==1)break;
	            if(n==tp || myset.find(n)!=myset.end()){ans++; break;}
	            else ans+=1;
	        }
	    }
	    cout<<ans<<lb;
	}
}



int main()
{
    fast()
    solve();
    return 0;
}


Measured memory_bytes: 3648