+ 1

Hello people, I have the doubt of how to start

average , major and minor. Of a variable set the number of students starts from scratch and the Add grade or Finish option is added, with which the user can add the grades one by one or finish.

14th May 2020, 3:28 AM
Benjamín Ramires
Benjamín Ramires - avatar
3 Respuestas
0
Resultado ; #include<stdio.h> #include<stdlib.h> int main(){     float calificaciones[???];     float promedio =0;     int mayor =0;     int menor =0;     float media =0;        for ( int i=0; i<=??; i++){     printf ("ingrese  la calificación que quieras %d\n",i );     scanf ("%f" ,&calificaciones[i]);     promedio +=calificaciones[i];  if(calificaciones [i]>calificaciones[mayor]){  mayor =i;  }  }    for(int i=0; i<??; i++){     if(calificaciones [i]< calificaciones [menor]){             menor=i;        } media = (promedio + calificaciones [i])/2; } printf  ("el medio es %2.f\n" , media ); printf ("el promedio es: %2.f\n" ,promedio );                        printf("calificacion menor: %d\n", menor); printf("\n esta en la posicion: %d\n",menor); printf("calificacion mayor: %d\n", mayor); printf("\n esta en la posicion: %d\n",mayor); return 0; }
14th May 2020, 3:36 AM
Benjamín Ramires
Benjamín Ramires - avatar
0
How would I add note and end And starting at 0
14th May 2020, 3:37 AM
Benjamín Ramires
Benjamín Ramires - avatar
0
Any advice would be appreciated
14th May 2020, 3:40 AM
Benjamín Ramires
Benjamín Ramires - avatar