Easy
Check whether two binary trees are structurally identical.
Return true if two binary trees have the same structure and node values.
Examples
Input: p = [1,2,3], q = [1,2,3]
Output: true
Constraints
- Trees may be empty
Coding Challenge
Check whether two binary trees are structurally identical.
Return true if two binary trees have the same structure and node values.
Input: p = [1,2,3], q = [1,2,3]
Output: true
Preparing your coding workspace...