💡JavaScript Solution
The idea\n1. Inorder: <LEFT><ROOT><RIGHT>, postorder: <LEFT><RIGHT><ROOT>\n2. The last element of postorder will always be the root of a subtree. We can furter 
### The idea\n1. Inorder: `<LEFT><ROOT><RIGHT>`, postorder: `<LEFT><RIGHT><ROOT>`\n2. The last element of postorder will always be the root of a subtree. We can furter determine its left and right subtree by finding its position in the inorder array. \n<img src="https://assets.leetcode.com/users/aminick/image_1580110093.png" width=600px>\n\n``` javascript\n/**\n * @param {number[]} inorder\n * @param {number[]} postorder\n * @return {TreeNode}\n */\nvar buildTree = function(inorder, postorder) {    \n    let hash = {};\n    for (let i=0;i<inorder.length;i++) hash[inorder[i]] = i; \n    \n    let recur = function(start, end) {\n        if (start > end) return null;\n        let val = postorder.pop();\n        let root = new TreeNode(val);\n        root.right = recur(hash[val] + 1, end);\n        root.left = recur(start, hash[val] - 1);\n        return root;\n    }\n    \n    return recur(0, inorder.length - 1);  \n};\n```
['JavaScript']