larscheng / algo

0 stars 0 forks source link

【Check 84】2024-05-28 - 169. 多数元素 #192

Open larscheng opened 4 months ago

larscheng commented 4 months ago

169. 多数元素

larscheng commented 4 months ago

思路

投票大法,



### 复杂度
- 时间复杂度:O(n)
- 空间复杂度:O(1)