diff --git a/notes/27. 二叉树的镜像.md b/notes/27. 二叉树的镜像.md index 18b5f0fa..7f803db4 100644 --- a/notes/27. 二叉树的镜像.md +++ b/notes/27. 二叉树的镜像.md @@ -1,6 +1,6 @@ # 27. 二叉树的镜像 -[牛客网](https://www.nowcoder.com/practice/a9d0ecbacef9410ca97463e4a5c83be7?tpId=13&tqId=11171&tab=answerKey&from=cyc_github) +[Leetcode](https://leetcode.cn/problems/er-cha-shu-de-jing-xiang-lcof/) ## 题目描述 @@ -9,12 +9,12 @@ ## 解题思路 ```java -public TreeNode Mirror(TreeNode root) { +public TreeNode flipTree(TreeNode root) { if (root == null) return root; swap(root); - Mirror(root.left); - Mirror(root.right); + flipTree(root.left); + flipTree(root.right); return root; }