text: public static int StrCmp(string str, char[] a, int start){int i, d, len = str.Length;for (i = 0; i < len; i++){d = (int)str[i] - a[start + i];if (d != 0){return d;}if (a[start + i] == 0){return d;}}if (a[start + i] != 0){return -a[start + i];}return 0;}