![17368230-7a54922c85b1fc1c.png](https://i-blog.csdnimg.cn/blog_migrate/f500cf46df46d6c4f991bbad00a039d1.webp?x-image-process=image/format,png)
class Solution:
# 返回镜像树的根节点
def Mirror(self, root):
# write code here
if root == None:
return root
temp = self.Mirror(root.right)
root.right = self.Mirror(root.left)
root.left = temp
return root