Could you please help me with pinning a problem down in my code?
The program is supposed to ask for the user to enter dog names and finally print the name of the third dog. When Icompile and execute the program, it says that "it stopped working" and windows asks me if I wanna close the program or do something else.
#include<iostream>
#include<cstdlib>
using namespace std;
main()
{
string perros[10];
int i;
for(i=1; i<11; i++)
{
cout<<"Introduce el nombre del perro"<<endl<<i;
cin>>perros[i];
}
cout<<"El nombre del tercer perro es "<<perros[2];
system("pause");
}