Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/neetcode-gh/leetcode
/ sumSquareDigits
Method
sumSquareDigits
python/0202-happy-number.py:12–17 ·
view source on GitHub ↗
(self, n)
Source
from the content-addressed store, hash-verified
10
return
True
if
fast == 1
else
False
11
12
def
sumSquareDigits(self, n):
13
output = 0
14
while
n:
15
output += (n % 10) ** 2
16
n = n // 10
17
return
output
Callers
1
isHappy
Method · 0.95
Calls
no outgoing calls
Tested by
no test coverage detected