You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Combinations and permutations use factorials; it could be fun. I know little about the state-of-the-art factorial algorithms, but a quick search gives some recursive divide-and-conquer stuff and a bunch of prime swings. I'd rather not prime sieve until I have a scalable sieve approach I'm content with, so maybe I'll try the recursive divide-and-conquer stuff.
The text was updated successfully, but these errors were encountered:
The first iteration of the loop is pointless so we skip it with a downshift by one. Note that the index is at least 2 at this point, so the shifted index is still nonzero. This patch only matters for small factorials, or not at all.
Combinations and permutations use factorials; it could be fun. I know little about the state-of-the-art factorial algorithms, but a quick search gives some recursive divide-and-conquer stuff and a bunch of prime swings. I'd rather not prime sieve until I have a scalable sieve approach I'm content with, so maybe I'll try the recursive divide-and-conquer stuff.
The text was updated successfully, but these errors were encountered: