Monday, 19 August 2013

What is the use of a hash key with ":"

What is the use of a hash key with ":"

I understand Hash : hash1 = Hash["a" => 100 , "b" => 200]
But i cant figure out what hash2 = Hash[:a => 100 , :b => 200] is.
Whats the difference between the keys? What is the use of a key with :?

No comments:

Post a Comment