[Solved] How to display values in a dictionary?


To list out just the items associated with the key:

String.Join(", ", items[key]);

To list out all products and all items:

foreach (var key in items.Keys)
{
    System.Console.WriteLine("{0}: {1}", key, String.Join(", ", items[key]));
}

1

solved How to display values in a dictionary?