Dev - C++ - ERROR AL COMPILAR

 
Vista:

ERROR AL COMPILAR

Publicado por GEFORCE (20 intervenciones) el 01/12/2021 01:38:07
#include<stdio.h>
#include<conio.h>
#include<string.h>
//6 equipos
char equipos[6][15];
int puntaje[6][5]; // pg pe pp gf puntaje
int i,j;
void ingreso();
void ordena_tabla();
void presenta_matriz();

void main()
{
clrscr();
ingreso();
presenta_matriz();
ordena_tabla();
presenta_matriz();
}

void ingreso()
{
int jugados;
for(i=0;i<6;i++)
{
printf("Ingrese nombre de equipo %d:",i+1);
scanf("%s", equipos[i]);
do{
printf("n Ingrese partidos ganados:");
scanf("%d", &puntaje[i][0]);
printf("n Ingrese partidos empatados:");
scanf("%d", &puntaje[i][1]);
printf("n Ingrese partidos perdidos:");
scanf("%d", &puntaje[i][2]);
jugados=puntaje[i][0]+puntaje[i][1]+puntaje[i][2]; //debe sumar 10
}while(jugados!=10);
printf("Ingrese goles a favor:");
scanf("%d", &puntaje[i][3]);
puntaje[i][4]=(puntaje[i][0]*3)+puntaje[i][1];
}
}

void presenta_matriz()
{
clrscr();
printf("EQUIPOS PG PE PP GF PUNTAJE");
for(i=0;i<6;i++)
{
printf("n %s", equipos[i]);
for(j=0;j<5;j++)
printf("%dt",puntaje[i][j]);
}
getch();
}



void ordena_tabla()
{
int aux,k;
char auxi[15];
for(k=1;k<=5;k++)
for(i=0;i<5;i++)
{
if((puntaje[i][4]<puntaje[i+1][4])||(puntaje[i][4]==puntaje[i+1][4]) && (puntaje[i][3]<puntaje[i+1][3]))
{
//intercambio de equipos
strcpy(auxi,equipos[i]);
strcpy(equipos[i],equipos[i+1]);
strcpy(equipos[i+1],auxi);

for(j=0;j<5;j++)
{
aux=puntaje[i][j];
puntaje[i][j]=puntaje[i+1][j];
puntaje[i+1][j]=aux;
}
}
}
}











gente me pueden ayudar de porque no me esta corriendo
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder