This is a Ruby tree! It shows every object from the Ruby Programming Language in a tree format.
# Hash.each_pair (from ruby core) --- hash.each {|key, value| ... } -> self hash.each_pair {|key, value| ... } -> self hash.each -> new_enumerator hash.each_pair -> new_enumerator --- Hash#each is an alias for Hash#each_pair. Calls the given block with each key-value pair; returns `self`: h = {foo: 0, bar: 1, baz: 2} h.each_pair {|key, value| puts "#{key}: #{value}"} # => {:foo=>0, :bar=>1, :baz=>2} Output: foo: 0 bar: 1 baz: 2 Returns a new Enumerator if no block given: h = {foo: 0, bar: 1, baz: 2} e = h.each_pair # => #<Enumerator: {:foo=>0, :bar=>1, :baz=>2}:each_pair> h1 = e.each {|key, value| puts "#{key}: #{value}"} h1 # => {:foo=>0, :bar=>1, :baz=>2} Output: foo: 0 bar: 1 baz: 2
This is MURDOC! A Ruby documentation browser inspired by Smalltalk-80. It allows you to learn about Ruby by browsing through its class hierarchies, and see any of its methods.