Subtree(LintCode 245):

Problem