#include<stdio.h>
#include<string.h>
int max(int a,int b)
{
if(a>b)return a;
return b;
}
int main()
int n,i,a[1001],b[10001],maxn=0,ans,sum=0;
scanf("%d",&n);
memset(b,0,sizeof(b));
for(i=1;i<=n;i++)
scanf("%d",&a[i]);
maxn=max(maxn,a[i]);
b[a[i]]++;
for(i=1;i<=maxn;i++)
if(sum<b[i]){ans=i;sum=b[i];}
printf("%d出現的bai次duzhi數最高dao。出現%d次",ans,sum);return 0;}
#include<stdio.h>
#include<string.h>
int max(int a,int b)
{
if(a>b)return a;
return b;
}
int main()
{
int n,i,a[1001],b[10001],maxn=0,ans,sum=0;
scanf("%d",&n);
memset(b,0,sizeof(b));
for(i=1;i<=n;i++)
{
scanf("%d",&a[i]);
maxn=max(maxn,a[i]);
b[a[i]]++;
}
for(i=1;i<=maxn;i++)
if(sum<b[i]){ans=i;sum=b[i];}
printf("%d出現的bai次duzhi數最高dao。出現%d次",ans,sum);return 0;}