Why does factorial(21) equal -4249290049419214848?
johnmyleswhite.com
johnmyleswhite.com
OTOH, if I had to calculate fib(X), and not fib(1..X), I'd use the exponential formula (relying on floating point) instead of the recurrence (which uses integer), so I guess the error would be detected at the conversion to integer.