@@ -0,0 +1,825 @@
+import java.util.Hashtable;%0A%0Apublic class Solution %7B%0A    public int majorityElement(int%5B%5D num) %7B%0A        int len = num.length;%0A        Hashtable%3CInteger, Integer%3E tb = new Hashtable%3CInteger, Integer%3E();%0A        int max = 0;%0A        %0A        for(int i = 0; i %3C len; i++)%7B%0A            int digit = num%5Bi%5D;%0A            %0A            if(!tb.containsKey(digit))%7B%0A                tb.put(digit, 1);%0A            %7D%0A            else%7B%0A                %0A                int val = tb.get(digit)+1;%0A                tb.put(digit, val);%0A            %7D%0A        %7D%0A        %0A        int target = 0;%0A        %0A        for (Integer key: tb.keySet()) %7B%0A             int tmp = tb.get(key);%0A             if(tmp %3E max)%7B%0A                 max = tmp;%0A                 target = key;%0A             %7D%0A         %7D%0A         %0A         return target;%0A        %0A    %7D%0A%7D%0A

Create MajorityElement_001.java