In the Matrix class constructor, you set the default for the content parameter like this:
constructor(width, height, content = () => undefined) (i.e. no parameters in the function)
But then in theSymmetricMatrix class constructor, set the default for the content parameter like this:
constructor(size, content = (x, y) => undefined) (i.e. x and y parameters in the function)
Is there a reason these are different?
In the
Matrixclass constructor, you set the default for the content parameter like this:constructor(width, height, content = () => undefined)(i.e. no parameters in the function)But then in the
SymmetricMatrixclass constructor, set the default for the content parameter like this:constructor(size, content = (x, y) => undefined)(i.e. x and y parameters in the function)Is there a reason these are different?