I got this function so far :
void sumcol(int a[r][c],int r,int c){
int i,j,sum=0;
//int sizec= sizeof(a)/sizeof(a[0][0]);
//int sizer= sizeof(a)/sizeof(a[0]);
for (i=0;i<r;i++){
for (j=0;j<c;j++) sum=sum+a[j][i];
cout<<"Suma pe coloana "<<i<<" este : "<<sum<<endl;
sum=0;
}
}
I get an error on the first line that r and c were not declared in this scope. Why? Though I read right there : https://www.eskimo.com/~scs/cclass/int/sx9a.html that this is a Correct way of declaring.