C# Program to find prime numbers in an array

In this program, You will learn how to find prime numbers in an array in C#. Some prime elements is: 5 7 11 13 Example: How to find prime numbers…

C# Program to find union and intersection of two arrays

In this program, You will learn how to find union and intersection of two arrays in C#. 1st list is: 1 2 3 4 5 2nd list is: 3 4…

C# Program to sort an array in descending order

In this program, You will learn how to sort an array in descending order in C#. List is: 1 4 2 3 5 After sort list is: 5 4 3…

C# Program to sort an array in ascending order

In this program, You will learn how to sort an array in ascending order in C#. List is: 5 4 2 3 1 After sort list is: 1 2 3…

C# Program to swap adjacent elements of an array

In this program, You will learn how to swap adjacent elements of an array in C#. 11 12 13 14 15 12 11 14 13 15 Example: How to swap…

C# Program to copy all elements of an array to another array

In this program, You will learn how to copy all elements of an array to another array in C#. arr2[i] = arr1[i] Example: How to copy all elements of an…

C# Program to find duplicate elements in the array

In this program, You will learn how to find duplicate elements in the array in C#. List is: 11 12 11 13 14 15 13 Duplicate elements are: 11 13…

C# Program to check a number is unique or not

In this program, You will learn how to check a number is unique or not in C#. Some List of unique numbers is: 1, 22, 456, 556 The unique number…

C# Program to search an element in the array

In this program, You will learn how to search an element in the array in C#. Array List is: 10 20 30 40 50 60 70 80 90 100 Enter…

C# Program to find the second smallest element in an array

In this program, You will learn how to find the second smallest element in an array in C#. Array List is: 10 20 30 40 50 60 70 80 90…