送分题

class Solution(object):
    def repeatedNTimes(self, A):
        """
        :type A: List[int]
        :rtype: int
        """
        count=collections.Counter(A)
        for val,num in count.items():
            if num==len(A)/2:
                return val
        

 

相关文章:

  • 2021-12-05
  • 2022-12-23
  • 2021-12-19
  • 2022-01-15
  • 2021-11-24
  • 2022-01-17
  • 2021-09-30
猜你喜欢
  • 2021-12-29
  • 2021-06-28
  • 2021-05-21
  • 2021-05-22
  • 2022-12-23
  • 2022-12-23
  • 2021-07-26
相关资源
相似解决方案