Hi Im writing a matrix class and i wondered if anyone knows how to write an operator to assign a value to the array using row and column for index. I had a go but am lost really :
void operator(int Row, int Col) = (double Value) ....
ie
Matrix M = new Matrix(3,3); // creates a 3x3 matrix
M(1,1) = 2;
Thanks in advance.
void operator(int Row, int Col) = (double Value) ....
ie
Matrix M = new Matrix(3,3); // creates a 3x3 matrix
M(1,1) = 2;
Thanks in advance.