Rowwise iteration of a dictionay object
- by mono
I have a dictionary object like:
Dictionary<string, HashSet<int>> dict = new Dictionary<string, HashSet<int>>();
dict.Add("foo", new HashSet<int>() { 15,12,16,18});
dict.Add("boo", new HashSet<int>() { 16,47,45,21 });
I have to print in such a way such that result would be as following at each iteration:
It1: foo boo //only the key in a row
It2: 15 16
It3: 16 47
Can anyone help me to achieve this. Thanks.