static void Main(string[] args) { int[,] x = { { 1, 2, 3 }, { 4, 5, 6 } }; int[,] y = { { 7, 8, 9 }, { 10, 11, 12 } }; var xy = new StitchMatrix <int>(x, y); Console.WriteLine("0,0=" + xy[0, 0]); // 1 Console.WriteLine("1,1=" + xy[1, 1]); // 5 Console.WriteLine("1,2=" + xy[1, 2]); // 6 Console.WriteLine("2,2=" + xy[2, 2]); // 9 Console.WriteLine("3,2=" + xy[3, 2]); // 12 }
static void Main(string[] args) { int[,] a = { { 1, 2, 3 }, { 4, 5, 6 } }; int[,] b = { { 7, 8, 9 }, { 10, 11, 12 } }; var ab = new StitchMatrix <int>(a, b); Console.WriteLine("0,0=" + ab[0, 0]); // 1 Console.WriteLine("1,1=" + ab[1, 1]); // 5 Console.WriteLine("1,2=" + ab[1, 2]); // 6 Console.WriteLine("2,2=" + ab[2, 2]); // 9 Console.WriteLine("3,2=" + ab[3, 2]); // 12 }