Console.WriteLine("Enter the number");
int num = Convert.ToInt32(Console.ReadLine());
int[] array = new int[num];
Array.Sort(array);
for(int i = 0;i < array[i] ;i++)
{
if (array[0] == array[i])
{
}
}
I have sorted and i am comparing every element of the array with the next element.
But how to remove the duplicate element??