Much better! Now we can compute F(500,000)F(500,000) without breaking a sweat: this took a little over 2 seconds on my machine.

Code
Output

Much better! Now we can compute F(500,000)F(500,000) without breaking a sweat: this took a little over 2 seconds on my machine.

Code
Output