From 82542292ebbc22f479f0c45c938ee1fa17109d63 Mon Sep 17 00:00:00 2001 From: weijiew <49638002+weijiew@users.noreply.github.com> Date: Tue, 4 May 2021 11:41:30 +0800 Subject: [PATCH] =?UTF-8?q?Update=200112.=E8=B7=AF=E5=BE=84=E6=80=BB?= =?UTF-8?q?=E5=92=8C.md?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修改了一个错字。最近在准备 ACM 省赛,非常感谢作者的题解! --- problems/0112.路径总和.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/problems/0112.路径总和.md b/problems/0112.路径总和.md index 429bb556..6c303f45 100644 --- a/problems/0112.路径总和.md +++ b/problems/0112.路径总和.md @@ -249,7 +249,7 @@ private: vector path; // 递归函数不需要返回值,因为我们要遍历整个树 void traversal(TreeNode* cur, int count) { - if (!cur->left && !cur->right && count == 0) { // 遇到了叶子节点切找到了和为sum的路径 + if (!cur->left && !cur->right && count == 0) { // 遇到了叶子节点且找到了和为sum的路径 result.push_back(path); return; }