Small factorials problem please help

The answer I did is

Just check if you can store the answer of 100 factorial in long int.

I used long long int(64) still same condition
What should I use then

You can check here on how to store big numbers in factorial .

1 Like

You can use “boost/multiprecision/cpp_int” in C++ for higher precision integers for such questions.