public static void SetArray(int[] arrayint)
{
// int[] arrayint = new int[100];
Random random = new Random();
for (int i = 1; i <= 1000; i++)
{
int index = random.Next(0, 1000);
if (arrayint[index] == 0)
arrayint[index] = i;
else i--;
}
foreach (int i in arrayint)
{
Console.Write(i);
Console.Write(" ");
}
}