Google

def initialize( parent = nil ) #puts "IN CHILD, PARENT IS #{parent.type}" @parent = nil # Declare @parent, but don't define it. The next line sets the # parent. parent.add( self ) unless parent.nil? end