Skip to content

bst.go tree.Delete() function mistake? #13

@WuShaoQiang

Description

@WuShaoQiang

if parent.Left == n {

I think it should be

if parent.Left == h

n is never gonna equal to parent.Left right?, they don't have the same address. We only use n pass to function Compare to determine which way should we go in the tree.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions