[LeetCode]515. Find Largest Value in Each Tree Row
题目Youneedtofindthelargestvalueineachrowofabinarytree.Example:Input:1/\32/\\539Output:[1,3,9]难度Medium方法对二叉树进行前序遍历,将每一行的最大值保存在dict中,最后返回对应的list即可python代码classTreeNode(object):def__init__(self,x):self.va