text: public static boolean endsWith(char s[], int len, String suffix) {final int suffixLen = suffix.length();if (suffixLen > len)return false;for (int i = suffixLen - 1; i >= 0; i--)if (s[len -(suffixLen - i)] != suffix.charAt(i))return false;return true;}