Easy

Quiz

#101 Symmetric Tree

APPROACH

Determine whether the binary tree rooted at root is symmetric — that is, whether it looks the same when reflected across its vertical center axis.

Example 1:

Input: root = [1,2,2,3,4,4,3]
Output: true

Example 2:

Input: root = [1,2,2,null,3,null,3]
Output: false
1 of 4
1:00

What is the optimal approach for this problem?