Check out example codes for "c# keyvaluepair". It will help you in understanding the concepts better.

Code Example 1

// When you use foreach to enumerate dictionary elements,
// the elements are retrieved as KeyValuePair objects.
Console.WriteLine();
foreach( KeyValuePair<string, string> kvp in openWith )
{
    Console.WriteLine("Key = {0}, Value = {1}", 
        kvp.Key, kvp.Value);  
}

Learn ReactJs, React Native from akashmittal.com