摘要: Follow up for "Find Minimum in Rotated Sorted Array":What if duplicates are allowed? Would this affect the run-time complexity? How and why? Suppose a 阅读全文
posted @ 2018-04-14 23:18 乐乐章 阅读(135) 评论(0) 推荐(0) 编辑
摘要: Given an array of size n, find the majority element. The majority element is the element that appears more than⌊ n/2 ⌋ times. You may assume that the 阅读全文
posted @ 2018-04-14 23:11 乐乐章 阅读(125) 评论(0) 推荐(0) 编辑