• Returns a binary tree node composed of the specified left subtree, value and right subtree.

    Parameters

    • value: any

      Value to be stored in the node

    • left: BinaryTree

      Left subtree of the node

    • right: BinaryTree

      Right subtree of the node

    Returns BinaryTree

    A binary tree

    Example

    const tree = make_tree(1, make_empty_tree(), make_empty_tree());
    display(tree); // Shows "[1, [null, [null, null]]]" in the REPL