סורי לא יודע פסקל יודע C
תבקש ממישהו שיתרגם לך אבל הסינטקס דיי דומה int array,i,j; //the array is initalized
int rare,temp;
int counter=0,countemp=0;
//n is the size of the array
for(i=0;i<n;i++)
{
temp=array;
for(j=0;j<=n;j++)
{
if(array==array)
counter++;
}
if(counter>=countemp)
rare=temp;
countemp=counter;
counter=0;
}
// and then print rare and time it showed countemp
עקרונית זה אמור לעבוד - ואם לא אז באסה אני דיי מסטול