(TreeNode p, TreeNode q)
| 1 | class Solution { |
| 2 | public boolean isSameTree(TreeNode p, TreeNode q) { |
| 3 | |
| 4 | if(p==null || q==null) |
| 5 | { |
| 6 | return (p==q); |
| 7 | } |
| 8 | |
| 9 | return (p.val==q.val) && isSameTree(p.left,q.left) && isSameTree(p.right,q.right); |
| 10 | |
| 11 | } |
| 12 | } |
nothing calls this directly
no outgoing calls
no test coverage detected