Hash table:
Does not specify the type, does not specify the length, does not specify the key value
Hashtable ht = new Hashtable (); Defined
HT[1] = 1;
Ht[' a '] = "abc";
ht["AB"] = ' a ';
HT[3.14] = 1.14;
Ht. ADD (2, "qwerty"); adding elements
Ht. Remove (' a '); Delete Element
foreach (Var x in HT. Values)
{
Console.WriteLine (x);
}//Traversal, because the type cannot be determined using the universal var type
Queue:
Advanced First Out
Not specified length, not specified type
Queue line = new Queue (); Defined
Line. Enqueue ("AAA"); Add to
Line. Enqueue (12345555555);
Line. Enqueue (' a ');
Console.WriteLine (line. Dequeue ()); Output, FIFO
Console.WriteLine (line. Count); Record the number of key values
foreach (var x in line)
{
Console.WriteLine (x);
}//Traverse the same
Stack:
Advanced Post-out
Specified type, not specified length
stack<int> stack = new stack<int> (); Defined
Stack. Push (183); Add to
Stack. Push (255);
Console.WriteLine (Stack. Pop ()); Output, LIFO
Console.WriteLine (Stack. Count); Record the number of key values
Traverse
....
Console.read ();
C # hash table & Queue & Stack