3 ms·
Reminds me of this (old) issue I recently came across wrt factorial in Julia (just googling to figure out promotion to handle 52! - the trick is using a bigint)
by e12e 9y ago
Reminds me of this (old) issue I recently came across wrt factorial in Julia (just googling to figure out promotion to handle 52! - the trick is using a bigint).
Point being, you're spot on about mixing types and even "simple" functions need not be trivial (for various reasons, eg: factorial of a negative number - might be defined as negative infinity):
https://github.com/JuliaLang/julia/issues/6579 https://github.com/JuliaLang/julia/issues/6579