How can I take input in this as the number of inputs are not specified.
if left node is null like in the example
if 4 is null then will the left view be
1 2 5
?
How to take input in this and regarding ans
What abt this??
if left node is null like in the example
if 4 is null then will the left view be
1 2 5
?
1
/ \
2 3
/ \ \
4 5 6
When viewed from the left , we would see the nodes 1,2 and 4.