toujours pareil

master^2
Lola CHALMIN 2 years ago
commit 1b4ca59123

@ -273,11 +273,12 @@ Filecand ChargementfileC(Filecand fC, int *nbC)//chargement du fichier dans cett
return fC;
}
int chargement (Candidat tCandAcc[], int tmax, FILEfe){// chargement des files cand et chx
int i;
int chargement (Candidat tCandAcc[], int tmax, FILE *fe){// chargement des files cand et chx
int i, nbCand;
Candidat c;
Choix chx;
fscanf( fe, "%d", nbCand );
fscanf( fe, "%d", &nbCand );
c = lireCa (fe);
@ -286,12 +287,12 @@ int chargement (Candidat tCandAcc[], int tmax, FILEfe){// chargement des files c
printf("La liste des candidats admis est complète\n");
return 0;
}
tCandAcc[i] = (Candidat *) malloc (sizeof(Candidat));
tCandAcc[i] = (Candidat*) malloc (sizeof(Candidat));
if (tCandAcc[i] == NULL ){
printf("Problème malloc\n");
return -1;
}
*tCandAcc[i] = c;
tCandAcc[i] = c;
fscanf( fe, "%d", &nbC);
for ( i=0 ; i<nbc ; i ++){
chx = lireC( fe );
@ -308,7 +309,7 @@ int chargement (Candidat tCandAcc[], int tmax, FILEfe){// chargement des files c
void test (void){
FILE *fe;
int menu1, tlog;
CandidattCand[120];
Candidat *tCand[120];
fe = fopen( "part4.don", "r");
if ( fe == NULL ){
@ -321,6 +322,7 @@ void test (void){
fC = ChargementfileC(fC, &nbC);
tlog = chargement (tCand, 120, fe);
Afftab(tCand, tlog);
/*

@ -52,8 +52,12 @@ Filecand enfC(Filecand fC, Candidat c);
Filechx enf(Filechx fchx, Choix c);
Choix def(Filechx fc);
Candidat defC(Filecand fC);
<<<<<<< HEAD
int chargement (Candidat tCandAcc[], int tmax, FILEfe);// chargement des files cand et chx
Filecand ChargementfileC(Filecand fC, int *nbC);//chargement pour la file d'attente
=======
int chargement (Candidat tCandAcc[], int tmax, FILE *fe);// chargement des files cand et chx
>>>>>>> e32572c7e16bdf2af0d2765fcbeb57f084929d24
void test (void);

Loading…
Cancel
Save