update value based on key dictionary c# code example Example: dictionary update c# myDictionary[myKey] = myNewValue;