program d
    use,intrinsic :: iso_fortran_env
    implicit none
    integer(int64)::n,i,j,ans
    integer(int64):: dn(1000000)=0, bn(0:5050)
    logical:: pn(1000000) = .true. 


    read*, n
    pn(1) = .false.

    do i=2,1000000
        if (pn(i)) then
            j=2
            do while(i*j <= 1000000)
                pn(i*j) = .false.
                j=j+1
            end do
        end if
    end do

    do i=2,1000000
        if (pn(i)) then
            do while(mod(n,i) == 0)
                n=n/i
                dn(i) = dn(i)+1
            end do
        end if
    end do
    ans = 0

    if (n > 1) ans=ans+1
    bn(:) = 0
    do i=100,1,-1
        bn((i*(i+1))/2) = i
    end do
    do i=2,5050
        bn(i) = max(bn(i),bn(i-1))
    end do

    do i=1,1000000
        ans=ans+bn(dn(i))
    end do
    print'(i0)', ans

end program d