Skip to content

Commit dc70471

Browse files
committed
Runtime: 1360 ms (Top 29.95%) | Memory: 14.2 MB (Top 70.39%)
1 parent aaa8540 commit dc70471

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

scripts/algorithms/0-9/4Sum II/4Sum II.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# Runtime: 1360 ms (Top 29.95%) | Memory: 14.2 MB (Top 70.39%)
12
class Solution:
23
def fourSumCount(self, nums1: List[int], nums2: List[int], nums3: List[int], nums4: List[int]) -> int:
34
n1n2 = defaultdict(int)
@@ -11,4 +12,4 @@ def fourSumCount(self, nums1: List[int], nums2: List[int], nums3: List[int], num
1112
ans = 0
1213
for s in n1n2:
1314
ans += n1n2[s] * n3n4[-s]
14-
return ans
15+
return ans

0 commit comments

Comments
 (0)