Apple logoApple
CodingMembers

All Nodes Distance K in Binary Tree (LC 863)

Members only

Given a binary tree, target node, and distance K, return every node exactly K edges from the target. Follow-ups cover duplicate values, K larger than the tree height, collecting all nodes within K, an...

SWE
tree
graph
bfs
dfs
medium
Frequency
Single report
Last asked
2026-08-16
Stage
onsite-coding

Log in to continue reading the full content

Comments

Sign in to join the discussion
Loading...