int[] a = new int[10]; Console.WriteLine("请输入十个数:"); for (int i = 0; i < 10; i++) { string s = Console.ReadLine(); int x = int.Parse(s); a[i] = x; }