brad sue
- 270
- 0
Hi,
Please I need help to do the following:
add the elements of each colunm of a matrix and
Count the number of colunm whose the sum is less than 1.
I did this: i is the indice of line , j =indice of colunm.. size = dimension of the square matrix.
for(j=0;j<size;j++)
{ for(i=0;i<size;i++)
{sum=sum+A[j];
if (sum<1)
count=count+1;}
}
The compiler says I am wrong . I have to turn this in few hours...
please help me!
Thanks
B
Please I need help to do the following:
add the elements of each colunm of a matrix and
Count the number of colunm whose the sum is less than 1.
I did this: i is the indice of line , j =indice of colunm.. size = dimension of the square matrix.
for(j=0;j<size;j++)
{ for(i=0;i<size;i++)
{sum=sum+A[j];
if (sum<1)
count=count+1;}
}
The compiler says I am wrong . I have to turn this in few hours...
please help me!
Thanks
B