|
//............................................................................................. #include <stdio.h> #include <iostream.h> #include <stdlib.h> #include <string.h> #pragma hdrstop
//............................................................................................. #pragma argsused void leerNombres(int index, char* buffer) { printf ("inserte nombre %d ", index+1); scanf("%s", buffer); }
void mostrarNombres(int index, char* buffer) { printf ("nombre alumno: %s \n", buffer); }
int main(int argc, char* argv[]) { const int noEntradas = 3; char nombre[noEntradas][10];
for(int x = 0; x < noEntradas; ++x) { leerNombres(x, nombre[x]); }
for(int x = 0; x < noEntradas; ++x) { mostrarNombres(x, nombre[x]); }
system ("pause"); return 0; }
|