var inorderTraversal = function(root) {
const res = []
inorderTraversalNode(root, (v) => res.push(v))
return res
};
var inorderTraversalNode = function(node, callback) {
if (node !== null) {
inorderTraversalNode(node.left, callback)
callback(node.val)
inorderTraversalNode(node.right, callback)
}
}