Algorithm/factorization/main.cc
2024-05-01 14:29:23 +08:00

17 lines
253 B
C++

#include <iostream>
using namespace std;
int main() {
int N;
cin >> N;
int count = 0;
for (int i = 2; i <= N; i++) {
while (i != N) {
if (N % i != 0)
break;
N /= i;
count++;
}
}
cout << count + 1 << endl;
}