how to get value that often appear? : int[] nilai = {12,10,8,6,12,12,34,10,8,6,9,9,34,12,6,8,10,34,12,10,9,12};
        
        int[] frekuensi = new int[23];
        
        
        for (int i=0; i<nilai.length; i++) {
            frekuensi[i] = 0;
        }
         
        for (int i=0; i<nilai.length; i++) {
            frekuensi[nilai[i]]++;
        }
        
        int modus = 0;
        for (int i=0; i<nilai.length; i++) {
            if (frekuensi[i] > modus) {
                modus = i;
            }
        }        
        System.out.println("Nilai Modusnya = " + modus);