Skip to content

Commit de07e1c

Browse files
authored
Update sum-game.py
1 parent 5ea892e commit de07e1c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Python/sum-game.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ def sumGame(self, num):
88
:rtype: bool
99
"""
1010
# (1) if both halfs have '?',
11-
# alice will try to choose a number from one half to maximize or minimize the diff of both half sums,
12-
# and bob will try to choose the same number from the other half to minimize or maximize the diff of both half sums.
11+
# alice will optimally choose 9 or 0 from one half to maximize or minimize the diff of both half sums,
12+
# and bob will optimally to choose the same number from the other half to minimize or maximize the diff of both half sums.
1313
# in the end, it turns that only one half has '?' and the diff of both half sums is still the same as original
1414
# (2) if smaller half has no '?', then alice wins
1515
# (3) if smaller half has '?'

0 commit comments

Comments
 (0)