일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 | 29 |
30 | 31 |
Tags
- 프로그래머스
- 30. Substring with Concatenation of All Words
- data science
- 109. Convert Sorted List to Binary Search Tree
- 715. Range Module
- Python
- Substring with Concatenation of All Words
- 컴퓨터의 구조
- 파이썬
- Class
- LeetCode
- 43. Multiply Strings
- Protocol
- Convert Sorted List to Binary Search Tree
- Python Implementation
- shiba
- DWG
- 운영체제
- attribute
- Regular Expression
- kaggle
- 시바견
- t1
- 밴픽
- Decorator
- 315. Count of Smaller Numbers After Self
- concurrency
- Python Code
- Generator
- iterator
Archives
- Today
- Total
목록Intersection of Two Arrays II (1)
Scribbling
LeetCode: 350. Intersection of Two Arrays II
Using double counters. class Solution: def intersect(self, nums1: List[int], nums2: List[int]) -> List[int]: from collections import Counter c1 = Counter(nums1) c2 = Counter(nums2) ret = [] for k in c2.keys(): ret.extend([k] * min(c1[k], c2[k])) return ret
Computer Science/Coding Test
2022. 1. 10. 22:04