Please point out my mistake

My solution link is CodeChef: Practical coding for everyone

There is no compilation error but i get wrong answer on submitting.

Thanks in advance

overflow, use arrays.

Hey
See if we take factorial of 100 then its decimal digit will be much greater so either use array overflow
or
use
#include <boost/multiprecision/cpp_int.hpp>
using namespace boost::multiprecsion;
and where u have declared factorial =1 ;
use cpp_int factorial=1;

STACK OVERFLOW