CollectionsUtil.CreateCaseInsensitiveHashtable()
using System;
using System.Collections;
using System.Collections.Specialized;
class TestCollectionsUtils
{
public static void Main()
{
Hashtable population1 = CollectionsUtil.CreateCaseInsensitiveHashtable();
population1["a"] = 1;
population1["b"] = 2;
population1["c"] = 3;
population1["d"] = 4;
Console.WriteLine("Case insensitive hashtable results:\n");
Console.WriteLine("{0}'s population is: {1}", "a", population1["a"]);
Console.WriteLine("{0}'s population is: {1}", "b", population1["b"]);
Console.WriteLine("{0}'s population is: {1}", "c", population1["d"]);
Console.WriteLine("{0}'s population is: {1}", "d", population1["D"]);
}
}
Related examples in the same category