Wrong test case?

  • 0

    My BST output seems a little bit different than the expected result although my output should be also valid.

    Here is the test case:

    This is expected result:

    This is my output:

    My result is a valid BST and should be accepted. Please correct me if I'm wrong.

  • 0

    @simonkey The data is too large to be displayed in the window (you should have seen a yellow alert text in the bottom right corner which is not included in your screenshot). So maybe the bottom row of nodes are not placed in the correct position.

  • 0

    @1337c0d3r The data displayed is full (although there is an alert) and you can see the tree data is correct according to node's neighbors.
    Anyway I think my result should be accepted.

Log in to reply

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.