Para pasar un array como parametro en una funcion debemos hacer lo siguiente.
string arrayPrueba[10] = {"Cero", "Uno", "Dos", "Tres", "Cuatro", "Cinco", "Seis", "Siete", "Ocho"};
void ArrayComoParametro(string& array[])
{
array[1] = "Otro Numero";
}
int init()
{
Alert(arrayPrueba[1]);
ArrayComoParametro(arrayPrueba);
Alert(arrayPrueba[1]);
}
0 respuestas hasta el momento ↓
Todavía no hay comentarios... Empiece usted rellenando el siguiente formulario.