function inOrderPredecessor() {
        $current = $this->left();
        while ($current->right() !== null) {
            $current = $current->right();
        }
        return $current;
    }
function inOrderPredecessor() {
        $current = $this->left();
        while ($current->right() !== null) {
            $current = $current->right();
        }
        return $current;
    }
function inOrderPredecessor ( ) { $ current = $ this -> left ( ) ; while ( $ current -> right ( ) !== null ) { $ current = $ current -> right ( ) ; } return $ current ; }
Note that this function is only safe to call when it has a predecessor.
@return BinaryTree
Note that this function is only safe to call when it has a predecessor .