January 2020
Intermediate to advanced
532 pages
13h 31m
English
Earlier, we discussed that generic functions cannot be supported by the memoize function. It would be most awesome if we can just annotate the functions as memoized while they are being defined. For example, the syntax would be like this:
@memoize fib(n) = n < 3 ? 1 : fib(n-1) + fib(n-2)
It turns out that there's already an awesome package called Memoize.jl that does the exact same thing. It is indeed quite convenient:

Here, we can observe the following:
Read now
Unlock full access