From 8aa44cb792364bd457b55a8b7f6befd3c96d7368 Mon Sep 17 00:00:00 2001 From: Joey Date: Sun, 1 Aug 2021 22:44:20 +1000 Subject: [PATCH] Update tree.md return var should be nodes --- thinkings/tree.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/thinkings/tree.md b/thinkings/tree.md index a22640356..6a54a0c4a 100644 --- a/thinkings/tree.md +++ b/thinkings/tree.md @@ -580,7 +580,7 @@ class Solution: # 叶子节点 if cur and not cur.left and not cur.right: if remain == cur.val: - res.append((path + [cur.val]).copy()) + nodes.append((path + [cur.val]).copy()) return # 选择 path.append(cur.val)