
101. Symmetric Tree
·
Algorithm
Symmetric Tree - LeetCode Level up your coding skills and quickly land a job. This is the best place to expand your knowledge and get prepared for your next interview. leetcode.com 1. in-order 접근(실패) class Solution: def isSymmetric(self, root: TreeNode) -> bool: trace = [] def dfs(cur): if not cur: trace.append(None) else: if not (not cur.left and not cur.right): dfs(cur.left) trace.append(cur.v..