Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- int main() {
- int X, N;
- int soma_tacas = 0;
- scanf("%d", &X);
- for (int i = 0; i < X; i++) {
- int nota;
- float soma = 0;
- int qtd_notas = 0;
- scanf("%d", ¬a);
- while (nota != 0) {
- soma = soma + nota;
- qtd_notas++;
- scanf("%d", ¬a);
- }
- int media = soma / qtd_notas;
- soma_tacas = soma_tacas + media;
- }
- printf("Elas beberam %d ta�as!\n", soma_tacas);
- return 0;
- }
Add Comment
Please, Sign In to add comment