How I calculated the 1,000,000th Fibonacci Number with Python
Published in
6 min readApr 5, 2021
No, the title is not clickbait at all! A few days ago I really wanted to find the optimal solution to calculating Fibonacci numbers and I wanted to try to calculate the 100,000th number in the sequence, but I thought; if I could calculate the 100,000th, what’s stopping me finding the 1,000,000th? So today, I am going to show you how I went about doing this and all the issues I came across.
The Fibonacci sequence is one of the most well known mathematical sequences and is the most basic example of recurrence relations. Each…