Tor Erik Linnerud | 15 May 18:37

Re: Access Hash in the same order that was created

ara.t.howard wrote:
> is that possible?

Hash preserves insertion order in Ruby 1.9

irb(main):026:0> RUBY_VERSION
=> "1.9.0"
irb(main):027:0> mh.each{|val| puts val[0]}
one
two
three
four

regards,
Tor Erik
--

-- 
Posted via http://www.ruby-forum.com/.


Gmane