For the following input, expected output is  instead of [3,2,null,1]. Why?
Where as for the following input, it is considering left node. Weird!!. Expected output is [1,null,2].
Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.