c# dictionary modify value code example
Example 1: dictionary update c#
myDictionary[myKey] = myNewValue;
Example 2: c# modify dictionary in loop
List<string> keys = new List<string>(colStates.Keys);
foreach(string key in keys)
{
colStates[key] += 4;
}