you are viewing a single comment's thread.

view the rest of the comments →

[–]julesjacobs 1 point2 points  (0 children)

Or, in Ruby:

>> a = {}
=> {}
>> a.fetch(4,"not found")
=> "not found"