Код: Выделить всё
class Solution{
public:
int digitsInFactorial(int N)
{
long long fact=1;
for(int i=2;i0){
res++;
fact/=10;
}
return res;
}
};
Подробнее здесь: https://stackoverflow.com/questions/785 ... -factorial
Код: Выделить всё
class Solution{
public:
int digitsInFactorial(int N)
{
long long fact=1;
for(int i=2;i0){
res++;
fact/=10;
}
return res;
}
};