摘要:
public static string ReverseWords(string array){if (string.IsNullOrEmpty(array)){throw new ArgumentException("");}int arrLen = array.Length;char[] strNew = new char[arrLen + 1]; //全部反转 for (int index... 阅读全文
摘要:
public static int MaxSubSequSum(int[] arr, ref int intStart, ref int intEnd){int MaxSum = 0;int TmpSum = 0;for (int i = 0, j = 0; j < arr.Length; j++){TmpSum += arr[j];//如果截止到当前位置之和(TmpSum)大于最大子序列和... 阅读全文