987. Vertical Order Traversal of a Binary Tree
987. Vertical Order Traversal of a Binary Tree
Description
Given the root
of a binary tree, calculate the vertical order traversal of the binary tree.
971. Flip Binary Tree To Match Preorder Traversal
971. Flip Binary Tree To Match Preorder Traversal
Description
You are given the root
of a binary tree with n
nodes, where each node is uniquely assigned a value from 1
to n
. You are also given a sequence of n
values voyage
, which is the desired pre-order traversal of the binary tree.
2061. Number of Spaces Cleaning Robot Cleaned
2061. Number of Spaces Cleaning Robot Cleaned
Description
A room is represented by a 0-indexed 2D binary matrix room
where a 0
represents an empty space and a 1
represents a space with an object . The top left corner of the room will be empty in all test cases.
1255. Maximum Score Words Formed by Letters
1255. Maximum Score Words Formed by Letters
Description
Given a list of words
, list of singleletters
(might be repeating)and score
of every character.
291. Word Pattern II
623. Add One Row to Tree
404. Sum of Left Leaves
270. Closest Binary Search Tree Value
270. Closest Binary Search Tree Value
Description
Given the root
of a binary search tree and a target
value, return the value in the BST that is closest to the target
. If there are multiple answers, print the smallest.