factorials get BIG really fast and exceed the limits of 32-bit unsigned integer variables by 13!.
If you want to play with them use a datatype that can handle huge numbers, or switch to an extended precision mathematics library like GMP.
Or use Ruby or Python that do not have these narrow limits.
Reputation Points: 404
Solved Threads: 180
Nearly a Posting Virtuoso
Offline 1,422 posts
since Jul 2005