增加注释

This commit is contained in:
ningwei.shi
2020-11-12 09:21:54 +08:00
parent cfdfa28857
commit 8a2f374f63

View File

@ -311,7 +311,9 @@ class Solution:
left = dp(root.left)
right = dp(root.right)
# 抢当前,则两个下家不抢
do = root.val + left[0] + right[0]
# 不抢当前,则下家随意
do_not = max(left) + max(right)
return do_not, do