parse the binary tree to expression