LeetcodeConstruct Binary Tree from Preorder and Inorder Traversal

Posted wuezs

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了LeetcodeConstruct Binary Tree from Preorder and Inorder Traversal相关的知识,希望对你有一定的参考价值。

题目链接:https://leetcode.com/problems/construct-binary-tree-from-preorder-and-inorder-traversal/

题目:

Given preorder and inorder traversal of a tree, construct the binary tree.

Note:
You may assume that duplicates do not exist in the tree.

思路:

递归。

算法