public int[] checkPrime3(BigInteger n) {
        char[] digits = n.toString().toCharArray();
        int count0 = 0, count1 = 0, count2 = 0;
        int[] c0 = new int[3], c1 = new int[3], c2 = new int[3];
        int[] c5 = new int[1];
        for (int i = 0; i < digits.length; i++) {
            char c = digits[i];
            if ('0' == c) {
                c0[count0] = i;
                count0++;
            } else if ('1' == c) {
                c1[count1] = i;
                count1++;
            } else if ('2' == c) {
                c2[count2] = i;
                count2++;
            }
            if (count0 >= 3) {
                return c0;
            }
            if (count1 >= 3) {
                return c1;
            }
            if (count2 >= 3) {
                return c2;
            }
        }


        return c5;
    }