Thursday, May 12, 2011

Majority element

This is a classic one, don't bing to solve it -- try to think about a solution. Find the majority element in an array. There is a linear solution with constant space. pay also attention to limit case.

No comments:

Post a Comment