Q. How do you create a hash (dictionary) in Ruby?
β
Correct Answer: (A)
{ key1: 'value1', key2: 'value2' }
Explanation: Hashes in Ruby are created using curly braces with key-value pairs.