flintforge
flintforge
By default, the number of loops of `timeit` is based on a heuristic, so that the duration of the test be long enough (around 0.2sec), before pulling the best timing,...
Iterating over an array without modifying it is elementary python. Doing it **efficiently** can be considered as a "trick" (or rather, good knowledge of python) Try the benchmark : ```...
There are many *perspectives* but, generally speaking, only one acceptable definition : https://www.lexico.com/en/definition/efficiently Are you assuming that `L[::-1]` and `reversed(L)` are effectively reversing the list ? **Reversed** is a _type_...
what about mentioning this notes in the code ? That would be very instructive for newcomers, doesn't it ?
Hi. What do you think about displaying the example with `d1 = {'a': 1, 'b':0}`, to show the differences between the two ?