Skip to content

Allow using array for constructing binary trees #39

Open
@czgdp1807

Description

@czgdp1807

Description of the problem

Idea of using arrays for constructing binary trees originated from #38 (comment) which uses arrays for constructing binary heaps.
The challenge is to make the change without breaking existing API. One approach can be using keyword arguments like, elements and the transformed API would look like,

def __new__(cls, key=None, root_data=None, comp=None,
                is_order_statistic=False, *args, **kwargs):

If the above is done then the existing tests for binary_trees.py can be shortened.

Example of the problem

References/Other comments

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions