
Matrices 3x5 Notas estudiantes.
Publicado por Diego (3 intervenciones) el 05/09/2014 15:18:13
Saludos!, tengo esta actividad y quisiera saber cómo agrego la suma de las columnas para sacar el debido promedio; tengo el código hasta acá pero me siento atascado.
Agradezco cualquier ayuda.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#include<iostream>
#include<cstdlib>
#define fil 2
#define col 2
using namespace std;
int main (){
float m[fil][col];
int f, c, i, s=0, prom;
for (f=0;f<fil;f++)
for (c=0; c<col;c++){
cout << "Ingresar notas estudiante #" << f+1 << " : "; //Ingreso de notas por estudiante
cin >> m[f][c];
}
system("PAUSE");
return 0;
}
Agradezco cualquier ayuda.
Valora esta pregunta


0