#include<iostream>
#include<fstream>
using namespace std;
long fr[999999999];
int main()
{int n,nr,i;
ifstream f("pr6_112");
f>>n;
for(i=1;i<=n;i++)
{f>>nr;fr[nr]++;}
for(i=1;i<=999999999:i++)
if(fr[i]>0){cout<<i<<" apare de "<<fr[i]<<" ori"<<endl;}
f.close();
return 0;}