How do I test my code?


  • 0
    N

    I'm a bit confused about how I am supposed to test my code for problems like "Maximum Depth of a Binary Tree" using the custom test cases section.

    The default test case is just two empty square brackets ([]), which seems to represent an empty tree. However, when I input something like [5, 5, 5], this translates to a tree with a depth of 2.

    What am I missing here? I don't see any instructions on how to use this customer test case runner.


  • 0

    hi @nmagerko, I'm sorry that this post did not get the help it deserves. I have just updated the FAQ, please see here for a clear explanation about what the tree representation means.


Log in to reply
 

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