mirror of
https://github.com/autistic-symposium/master-algorithms-py.git
synced 2025-05-22 08:21:12 -04:00
Update intersection_two_arrays.py
This commit is contained in:
parent
2fe4c94c7f
commit
2d0842019d
1 changed files with 1 additions and 1 deletions
|
@ -10,7 +10,7 @@ def intersect(nums1: list[int], nums2: list[int]) -> list[int]:
|
|||
counter = Counter(nums1) & Counter(nums2)
|
||||
|
||||
for n in set_nums:
|
||||
result.extend([n]*counter[n])
|
||||
result.extend([n] * counter[n])
|
||||
|
||||
return result
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue