while ( $self ) { $path += $self->get_branch_length if $self = $self->get_parent; } return $path;