P
psykoprogrammer
I have a situation where I have two Dictionary<string, string> objects
and I need to combine them. More the point I need to update the value
of all the keys in dictionary A with values from matching keys in
dictionary B. Any keys in dictionary B that do no exist in dictionary
A are to be inserted into A. To illustrate:
Dictionary A:
Name, Adam
Age, 30
Dictionary B:
Name, Bob
Job, Dishwasher
Resulting Dictionary:
Name, Bob
Age, 30
Job, Dishwasher
What would be the most effecient way to accomplish this in .NET 3.5?
Is Dictionary even the right choice?
Thanks!
and I need to combine them. More the point I need to update the value
of all the keys in dictionary A with values from matching keys in
dictionary B. Any keys in dictionary B that do no exist in dictionary
A are to be inserted into A. To illustrate:
Dictionary A:
Name, Adam
Age, 30
Dictionary B:
Name, Bob
Job, Dishwasher
Resulting Dictionary:
Name, Bob
Age, 30
Job, Dishwasher
What would be the most effecient way to accomplish this in .NET 3.5?
Is Dictionary even the right choice?
Thanks!