Happy National Poetry Day to all those who celebrate.
Here’s a poem called ‘In Search of Poetry’. It’s constructed entirely from popular Google searches about poetry.
The fastest method in Julia is probably to call the optimized C implementation from the underlying libgmp library: function fastfib(n) z = BigInt() ccall((:__gmpz_fib_ui, :libgmp), Cvoid, (Ref{BigInt}, Culong), z, n) return z end This is about 50% faster than your memo-ized fib implementation above (which means your fib function is quite good)!
Happy National Poetry Day to all those who celebrate.
Here’s a poem called ‘In Search of Poetry’. It’s constructed entirely from popular Google searches about poetry.
Via Meidas Touch: