using System;
using System.Collections.Generic;
public class Example
{
public static void Main()
{
Dictionary openWith = new Dictionary();
openWith.Add("A", "a");
openWith.Add("B", "b");
openWith.Add("C", "c");
try
{
openWith.Add("A", "a");
}
catch (ArgumentException)
{
Console.WriteLine("already exists.");
}
}
}