Binary tree Flashcards

1
Q

Binary Tree maximum path sum

A

You know it.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Height of Binary Tree after Subtree Removal Queries - G

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Number of good leaf nodes pairs

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Diameter of binary tree

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Validate binary search tree

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Serialize and deserialize N-ary tree

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Serialize and deserialize binary tree

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Equal tree partition

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Symmetric tree

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Count nodes equal to average of subtree

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Delete nodes and return forest

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Construct string from binary tree

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Lowest common ancestor

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Lowest common ancestor - when nodes may not may not exist

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Lowest common ancestor - with pointer to parent and nodes as input

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Lowest common ancestor - when N nodes all exist

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

Construct binary from preorder and in order traversal

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

Find largest value in each tree row

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

Binary tree right side view

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

Binary tree vertical order traversal

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

Binary tree level order traversal

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

Binary tree level order traversal - bottom up

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

Binary tree preorder

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

Binary tree in order

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Q

Binary tree post order

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
26
Q

Convert binary search tree to sorted double linked list

A

You know it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
27
Q

Flatten binary tree to linked list preorder

A

You know it

28
Q

K-th smallest value in BST

A

You know it, in order traversal

29
Q

Delete node in a BST

A

You know it

30
Q

Delete subtree that sums to 0 and return number of nodes that remain

A

You know it

31
Q

Invert binary tree - the mirror of tree

A

You know it

32
Q

Binary tree return all paths to leaves

A

You know it

33
Q

Collect leaves and remove leaves of binary tree - G

A

You know it, tree height

34
Q

Reverse odd levels of binary tree

A

You know it

35
Q

Print binary tree in matrix

A

You know it

36
Q

Find mode in binary search tree (the most frequently occurred element)

A

You know it

37
Q

Sum of distances for all nodes in tree - G

A

You know it

38
Q

Find number of coins to place in tree nodes - G

A

You know it

39
Q

House Robber III - cannot take directly linked house

A

You may not know it well

40
Q

Construct binary tree from string with parentheses - F

A

You may not know it

41
Q

Binary Tree Vertical Traversal - sorted by value in the same row

A
42
Q

Binary search tree iterator

A

You know it

43
Q

Undirected graph valid tree

A

You know it

44
Q

Minimum height trees - G, F

A

You know it

45
Q

Boundary of binary tree - F

A

You know it

46
Q

Merge two binary trees

A

You know it

47
Q

Average of levels in binary tree

A

You know it

48
Q

Longest univalue path in binary tree - F

A

You know it

49
Q

Smallest subtree with all the deepest nodes - F

A

You know it

50
Q

All nodes with distance K from a target node (not root) in binary tree

A

You know it

51
Q

Add nodes into complete binary tree

A

You know it

52
Q

Range sum of binary search tree

A

You know it

53
Q

Construct binary search tree from preorder traversal - F

A

You know it

54
Q

Recover a tree from preorder traversal with dash - F

A

You know it

55
Q

Undirected tree diameter - F

A

You know it

56
Q

Balance binary search tree

A

You know it

57
Q

Check if a binary tree is balanced

A

You know it

58
Q

Closest binary search tree value

A

You know it

59
Q

Populate next right pointers in each node - G

A

You know it

60
Q

Sum root to leaf numbers - F

A

You know it

61
Q

Diameter of N-ary tree - F

A

You know it

62
Q

Maximum level sum of binary tree - F

A

You know it

63
Q

Binary tree zigzag level traversal - G, F

A

You know it

64
Q

Check completeness of binary tree - F

A

You know it

65
Q

Minimum time to collect all apples in tree - F

A

You know it

66
Q

Binary tree path sum equal to target

A

You know it