d3dx939dll

Aula24 - Vetores III

Dec 30th, 2020 (edited)
152
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.54 KB | None | 0 0
  1. #include <stdio.h>
  2.  
  3.  int main(void){
  4.     float notas[5] = {0};
  5.     float total = 0;
  6.     float media = 0;
  7.  
  8.     printf(" = = = Insira Cinco Dados: = = =\n");
  9.  
  10.     for(int i = 0; i < 5; ++i){
  11.  
  12.         printf(">>");
  13.         scanf("%f", &notas[i]);
  14.     }
  15.     for (int i = 0; i < 5; ++i)
  16.         total += notas[i];
  17.  
  18.     media = total / 5;
  19.  
  20.     printf("A Media Do Aluno e  >>%f<<\n", media);
  21.  
  22.     return 0;
  23.  }
  24.  
  25. // Aula: Vetores Part III (#24)
  26. // Data:30/12/2020
  27. // Grupo: reddit.com/r/heikoa
  28.  
  29. // Referencia:
  30.  
  31. // Video: https://www.youtube.com/watch?v=GmTpl5VRA4s
  32.  
Add Comment
Please, Sign In to add comment