KeyError
KeyError has not been discovered yet
Raised when the specified key is not found. It is a subclass of IndexError.
h = {"foo" => :bar} h.fetch("foo") #=> :bar h.fetch("baz") #=> KeyError: key not found: "baz"
KeyError has not been discovered yet
Raised when the specified key is not found. It is a subclass of IndexError.
h = {"foo" => :bar} h.fetch("foo") #=> :bar h.fetch("baz") #=> KeyError: key not found: "baz"
Join us on our quest to discover all of Ruby's Exceptional Creatures! Society members will receive new creatures as we discover them (we'll be adding more in the coming months). Oh, and you'll learn a lot about Ruby, too.