Mega Code Archive

 
Categories / Ruby / Hash
 

Element Assignment

h = { "a" => 100, "b" => 200 } h["a"] = 9 h["c"] = 4 puts h