From: Jeff Peng Date: 2010-01-21T22:38:47+09:00 Subject: Re: Unexpected Hash#first return under Ruby1.9 在 2010-01-21四的 22:22 +0900,Iñaki Baz Castillo写道: > Hi, Ruby 1.9 implements "first" method for Hash (as Hash are ordered now). > However the return value if a bit annoying for me. A real example: > > irb> h = {"aaa"=>"AAA", "bbb"=>"BBB"} > irb> h.first > ["aaa", "AAA"] > Since the result is an array you can access its element with the array way: irb(main):007:0> h.first[1] => "AAA"