[erlang-questions] finding the nearest key in a key-value table
Jesper Louis Andersen
Tue May 27 14:30:25 CEST 2014
On Tue, May 27, 2014 at 2:27 PM, Joe Armstrong <erlang@REDACTED> wrote:
> Seems to work - so to find the K nearest I just iterate prev and next
> keeping track of
> which direction I have to move - very nice.
Yes. Coincidentally, this is also the approach taken by the fastest
knapsack solver in existence, together with a dynamic programming table.
But I digress :)
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the erlang-questions