Lionel Thiry wrote: >> class << [] >> p inside_metaclass? #=> true >> end > > Sorry for the newbie question, but what does this mean? class << obj enters the idioclass of an object which is a class that contains method that will only be defined for that particular object. When obj = "Pacman -> (<" then class << obj def reverse() ">) <- Pacman" end end is the same as def obj.reverse() ">) <- Pacman" end So we provide a custom implementation of reverse() for a single method only -- you can also use this for adding completely new functionality. So why is the class << obj syntax necessary at all? To apply other class abilities to a single object. You might want to create an accessor for only one single object: obj = Array.new class << obj attr_accessor :creator end obj.creator # => nil obj.creator = ENV["username"] obj.creator # => "flgr" (your result may vary ;)) obj << "foo" obj << "bar" obj # => ["foo", "bar"] But even after that code: ary = Array.new ary.creator # raises NoMethodError Oh, and p obj just outputs an object's state for debugging. (It is the same as doing puts obj.inspect)