Exemple #1
0
        static void Main()
        {
            MyClass my = new MyClass();

            my[1, 1] = 2;

            Console.WriteLine(my[1, 1]);
            Console.WriteLine(my[0, 0]);

            // Delay.
            Console.ReadKey();
        }
Exemple #2
0
        static void Main()
        {
            MyClass my = new MyClass();

            for (int i = 0; i < 6; i++)
            {
                my[i] = string.Format("string {0}", i);
            }

            for (int i = 0; i < 6; i++)
            {
                Console.WriteLine(my[i]);
            }

            // Delay.
            Console.ReadKey();
        }
Exemple #3
0
        static void Main()
        {
            MyClass my = new MyClass();

            my[0] = "string 1";
            my[1] = "string 2";
            my[2] = "string 3";
            my[3] = "string 4";
            my[4] = "string 5";
            my[5] = "string 6";

            Console.WriteLine(my[0]);
            Console.WriteLine(my[1]);
            Console.WriteLine(my[2]);
            Console.WriteLine(my[3]);
            Console.WriteLine(my[4]);
            Console.WriteLine(my[5]);

            // Delay.
            Console.ReadKey();
        }