private static int countChars(int[] codePoints, int start, int end) {
    int count = 0;
    for (int i = start; i < end; i++) {
      count += Character.charCount(codePoints[i]);
    }
    return count;
  }
private static int countChars(int[] codePoints, int start, int end)