Majority element, python