Skip to content

Vertical Traversal of Binary tree #2344

@ishika22

Description

@ishika22

Problem Title
Printing a Binary Tree in Vertical Order.
Problem Description
We will be printing a binary tree in vertical order.
Sample testcase

image

Output: 4,2,1,5,3,6
Explanation:
As we can see there are 5 vertical lines which can pass through the tree -
1st vertical line - 4
2nd vertical line - 2
3rd vertical line - 1,5
4th vertical line - 3
5th vertical line - 6
Additional Context:
I have a solution for the above problem. Can this be accepted under the data structure folder!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions