On Tue, Apr 23, 2013 at 8:20 AM, kavita kulkarni
<kavitahkulka...@gmail.com>wrote:

>
> I have prefixed keys with numbers & used hash sorting, that resolved the
> issue.


Hmm, why not an array of <something> (e.g. anon. hashes) then?  If you're
creating them in order, just push them on an array - got to be cheaper than
sorting hash keys later on, right?

I guess I thought one of the points of a hash (vs an array) was random
access to a particular key/value pair, but if you want sequential access,
that's what arrays give you.  My guess is we're missing some part of the
problem you're solving this way.


-- 

a

Andy Bach,
afb...@gmail.com
608 658-1890 cell
608 261-5738 wk

Reply via email to