private static int GetMaxStempAmount(LinearAddressingHashTable table, int[] numbers) { int max = 1; for (int i = 0; i < numbers.Length; i++) { table.Add(numbers[i], numbers[i]); max = table.GetSteps() > max?table.GetSteps() : max; } return(max); }
private static int GetMaxHashTableListLength(List <int[]> arrays) { int maxListLength = 0; for (int i = 0; i < arrays.Count(); i++) { var table = new LinearAddressingHashTable(arrays[i].Length); int currTableMaxLength = GetMaxStempAmount(table, arrays[i]); maxListLength = currTableMaxLength > maxListLength ? currTableMaxLength : maxListLength; } return(maxListLength); }