- Dfs the binary tree and check the pre-order
- If left-node's val is not equal to the voyage, must flip the root
- If root's val is not equal to the voyage, It's invalid
971
Folders and files
Name | Name | Last commit date | ||
---|---|---|---|---|
parent directory.. | ||||
Name | Name | Last commit date | ||
---|---|---|---|---|
parent directory.. | ||||