mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-04-30 16:01:14 -04:00
825 B
825 B
id, title, challengeType, forumTopicId, dashedName
| id | title | challengeType | forumTopicId | dashedName |
|---|---|---|---|---|
| 5900f40d1000cf542c50ff1f | Problem 160: Factorial trailing digits | 1 | 301794 | problem-160-factorial-trailing-digits |
--description--
For any N, let f(N) be the last five digits before the trailing zeroes in N!.
For example,
$$\begin{align} & 9! = 362880 \; \text{so} \; f(9) = 36288 \\ & 10! = 3628800 \; \text{so} \; f(10) = 36288 \\ & 20! = 2432902008176640000 \; \text{so} \; f(20) = 17664 \end{align}$$
Find f(1,000,000,000,000)
--hints--
factorialTrailingDigits() should return 16576.
assert.strictEqual(factorialTrailingDigits(), 16576);
--seed--
--seed-contents--
function factorialTrailingDigits() {
return true;
}
factorialTrailingDigits();
--solutions--
// solution required