I have a bool variable and a Dictionary.
if it is true I have to increase value of my dictionary by 1 at a specified Key.
My Code :
private void Process(Person person)
{
isSendMailSuccessful = true;
if (isSendMailSuccessful)
{
MyDictionary.Where(i => i.Key == person.personID);
// I need to increase Value of that ID by 1
}
}
Why are you using LINQ fot this, and not just the Indexer of the Dictionary?
Something like