Skip to content

[BFS] Binary Tree Level Order Traversal #27

@sudosf

Description

@sudosf

Problem

Return the level-order traversal of a binary tree's values as a list of lists.

References

Difficulty

🟡 Medium

Companies

Amazon, Google, Goldman Sachs

Notes

Language: Java
Track level size at each iteration using queue.size() before the inner loop.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bfsBreadth-first searchmediumMedium difficultytreeTree problems

    Projects

    Status
    Backlog

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions