class Solution {
public:
void mirror(TreeNode* root) {
if(root==NULL) return;
mirror(root->left);
mirror(root->right);
TreeNode* tmp=root->left;
root->left=root->right;
root->right=tmp;
return;
}
};
标签:tmp,right,二叉树,mirror,镜像,root,left
From: https://www.cnblogs.com/tangxibomb/p/17266424.html