using System;
using System.Collections.Generic;
using System.Text;
namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{
int[] a = new int[10];
Random ran=new Random();
for (int i = 0; i < 10; i++)
{
int b = ran.Next(1, 100);
a[i] = b;
}
Array.Sort(a);
for (int j = 9; j >=0; j--)
{
Console.WriteLine(a[j]);
}
}
}
}
程序已调试过了。。可行。