static void Main(string[] args)
        {
            int[,] A = { { 1, 2, 3 }, { 4, 5, 6 }, { 7, 8, 9 } };
            int[] B = new int[10];
            int n = 0;
            for (int i = 0; i < 3; i++)
            {
                for (int j = 0; j < 3; j++)
                {
                    B[n++] = A[i, j];
                }
            }

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

            Console.Read();
        }
posted on 2019-11-04 10:00  .net之路  阅读(156)  评论(0编辑  收藏  举报