simplify with seperate node.py
add TreeNode
simplify with TreeNode