in reply to Re: how to loop through hash tables more efficiently
in thread updated_again: how to loop through hash tables more efficiently

will generally be faster than fetching a key and then looking up the value.

microscopically faster

  • Comment on Re^2: how to loop through hash tables more efficiently

Replies are listed 'Best First'.
Re^3: how to loop through hash tables more efficiently
by Anonymous Monk on Sep 18, 2012 at 07:27 UTC

    Indeed; the real speed gain comes from the iterator-like workings of each -- no need to build a list of keys to feed to foreach before even starting the loop (and at 20k keys, that costs quite a bit).