master
Guillaume 2 years ago
parent 77e791bdc4
commit 8abf1facd6

@ -728,7 +728,6 @@ void menuAdmin(VilleIut **villeIut, int nbVilles)
} }
} }
int creerCandid(Candidat tCand[], int nbCandidats) int creerCandid(Candidat tCand[], int nbCandidats)
{ {
int i=0; int i=0;
@ -756,14 +755,14 @@ int creerCandid(Candidat tCand[], int nbCandidats)
while(i<4) while(i<4)
{ {
printf("Rentrez une note : "); printf("Rentrez une note : ");
scanf("%f", c.notes[i]); scanf("%f", &c.notes[i]);
printf("%f", c.notes[i]); printf("%f", c.notes[i]);
i = i + 1; i = i + 1;
} }
printf("Nombre de choix de candidatures : "); printf("Nombre de choix de candidatures : ");
scanf("%d%*c", &c.nbChoix); scanf("%d%*c", &c.nbChoix);
c.choix = (Choix *) malloc (c.nbChoix*sizeof(Choix)); c.nbChoix = (Choix *) malloc (c.nbChoix*sizeof(Choix));
if(c.choix==NULL) if(c.nbChoix==NULL)
{ {
printf("Problème malloc\n"); printf("Problème malloc\n");
exit(1); exit(1);

Loading…
Cancel
Save