This is yet another challenge about the Fibonacci numbers.
The goal is to compute the 20'000'000th Fibonacii number as fast as possible. The decimal output is about 4 MiB large; it starts with:
The MD5 sum of the output is
You have to submit a program that calculates the number while running and puts the result to
stdout. The fastest program, as measured on my own machine, wins.
Here are some additional rules:
- You have to submit the source code and a binary runnable on an x64 Linux
- The source code must be shorter than 1 MiB, in case of assembly it is also acceptable if only the binary is that small.
- You must not include the number to be computed in your binary, even in a disguised fashion. The number has to be calculated at runtime.
- My computer has two cores; you are allowed to use parallelism
I took a small implementation from the Internet which runs in about 4.5 seconds. It should not be very difficult to beat this, assuming that you have a good algorithm.