public HashTableArray(int capacity) { _array = new HashTableArrayNode <TKey, TValue> [capacity]; for (int i = 0; i < capacity; i++) { _array[i] = new HashTableArrayNode <TKey, TValue>(); } }
public _002_HashTableArrayNode() { var instanse = new HashTableArrayNode <string, string>(); instanse.Add("1", "2"); instanse.Add("2", "4"); instanse.Add("3", "3"); instanse.Update("22", "22"); if (instanse.TryGetValue("2", out var result)) { Console.WriteLine($"result: {result}"); } foreach (var item in instanse) { Console.WriteLine(item); } }