#include <stdio.h>
#include <stdlib.h>
#include <math.h>
int main()
{
long a[10]={0};
long n,k;
printf("请输入数字:\n");
scanf("%ld",&n);
while(n>0){
k=n%10;
a[k]=a[k]+1;
n/=10;
}
printf("dight: \t");
for(k=0;k<10;k++){
if(a[k]>1)
printf("%ld\t",k);
}
printf("\n");
printf("occurrences:\t");
for(k=0;k<10;k++){
if(a[k]>1)
printf("%ld\t",a[k]);
}
return 0;
}