#T467. 复原二叉树

复原二叉树

Description

Little Tu is working on a data structure assignment. One of the problems gives you the pre-order traversal and in-order traversal results of a binary tree and asks you to write the post-order traversal result of that tree.

Input Format

The input contains multiple test cases. Each input consists of two strings representing the pre-order traversal and in-order traversal results of a binary tree. Each string is composed of unique uppercase letters.

Output Format

For each input, output the corresponding post-order traversal result of the binary tree.

```input1 DBACEGF ABCDEFG BCAD CBAD ``` ```output1 ACBFGED CDAB ``` ```markdown ## Source

CodesOnline