hopw to check how many duplicates in an array c code example
Example: hopw to check how many duplicates in an array c
/**
* C program to count total number of duplicate elements in an array
*/
#include
#define MAX_SIZE 100 // Maximum array size
int main()
{
int arr[MAX_SIZE];
int i, j, size, count = 0;
/* Input size of array */
printf("Enter size of the array : ");
scanf("%d", &size);
/* Input elements in array */
printf("Enter elements in array : ");
for(i=0; i