Ruby/Hash/Converrt to Hash
Материал из Wiki.crossplatform.ru
Версия от 17:10, 26 мая 2010; (Обсуждение)
Convert hash to a hash and check the object id
myHash = { 1920 => "value for 1920", 1925 => "value for 1925", 1934 => "value for 1934" } fitz = myHash.to_hash # => {1925=>"value for 1925", 1920=>"value for 1920", 1934=>"value for 1934"} fitz.object_id # => 1745050 myHash.object_id # => 1745050