matthewsamuel95 / ACM-ICPC-Algorithms

Algorithms used in Competitive Programming
2.07k stars 1.26k forks source link

add extra long factorial in go #927

Closed ridwanfathin closed 5 years ago

ridwanfathin commented 5 years ago

The factorial of the integer n, written n!, is defined as:

n! = n x (n-1) x (n-2) x ... x 3 x 2 x 1

Calculate and print the factorial of a given integer.

Note: Factorials of n > 20 can't be stored even in a 64bit long long variable. Big integers must be used for such calculations. We recommend solving this challenge using BigIntegers.