I have some lines from text files that i want to add into the Dictionary.I am using Dictionary for the first time.While adding up starting lines it was Ok but suddenly i got err
Example:
class Program
{
private static List> d = new List>();
static void Main(string[] args)
{
d.Add(new KeyValuePair("joe", 100));
d.Add(new KeyValuePair("joe", 200));
d.Add(new KeyValuePair("jim", 100));
var result = d.Where(x => x.Key == "joe");
foreach(var q in result)
Console.WriteLine(q.Value );
Console.ReadLine();
}
}