Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace DictinariesWithLists
- {
- class DictinariesWithLists
- {
- static void Main()
- {
- Dictionary<string, string> phonebook = new Dictionary<string, string>();
- phonebook["John Smith"] = "+1-555-8976";
- phonebook["Lisa Ann"] = "+1-5585-99969";
- phonebook["Sam Doe"] = "+1-7746-5596";
- foreach(var ph in phonebook)
- {
- Console.WriteLine("{0} --> {1}",ph.Key,ph.Value);
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment