You are on page 1of 1

#include <iostream.

h>
#include <conio.h>
void main(){
int num[100];
int x, y, z;
for(x=1;x<=100;x++){
cout << "Ingrese un numero " << x << ": ";
cin >> num[x];
cout << "\n";
}
for(x=1;x<=100;x++){
for(y=1;y<=100;y++){
if(num[x] == num[y])
z = z + 1;
}
if(x==1 && z==0){
cout << num[x] << " se repitio: 1 veces." << endl;
}
else{
if(z!=0 && z<=100){
cout << num[x] << " Se repitio: " << z <
< " veces." << endl;
}
z=0;
}
}
getch();
return 0;
}

You might also like