1817. Finding the Users Active Minutes
Содержание
class Solution:
def findingUsersActiveMinutes(self, logs: List[List[int]], k: int) -> List[int]:
d = defaultdict(set)
for i, t in logs:
d[i].add(t)
res = [0] * k
for ts in d.values():
res[len(ts) - 1] += 1
return res