Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Jack-Lee-Hiter/AlgorithmsByPython
/ canWinNim
Method
canWinNim
leetcode/292. Nim Game.py:10–12 ·
view source on GitHub ↗
(self, n)
Source
from the content-addressed store, hash-verified
8
9
class
Solution(object):
10
def
canWinNim(self, n):
11
return
True
if
n%4 != 0
else
False
12
# return bool(n%4)
Callers
nothing calls this directly
Calls
no outgoing calls
Tested by
no test coverage detected