using System.Collections.Generic; using System.Collections;
Dictionary<Tuple<int, int>, int> dic = new Dictionary<Tuple<int, int>, int>(); dic.Add(new Tuple<int, int>(1, 2), 100); dic.Add(new Tuple<int, int>(1, 3), 200); dic.Add(new Tuple<int, int>(2, 1), 300); int result = dic[new Tuple<int, int>(1, 3)]; //200