add solution for same tree.