how make sum of matriks which the ordo inputed by user? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

how make sum of matriks which the ordo inputed by user?

15th Sep 2016, 12:11 PM
nisa905
nisa905 - avatar
2 Answers
+ 1
how if the matrix have two or more dimention?
16th Sep 2016, 1:18 AM
nisa905
nisa905 - avatar
0
you have to use arrays to do so for eg. a[]={1,2,3,4}; b[]={1,2,3,4}; c[]=new int [4]; for(int I=0;I<=3;I++){ c[I]=a[I]+b[I]; sopln (c[I]); }
15th Sep 2016, 3:25 PM
Saransh Agarwal
Saransh Agarwal - avatar