get-matrix-sums
v1.1.0
Published
Get matrix sums
Downloads
2
Readme
get-matrix-sums
Installation
npm install get-matrix-sums --save
Syntax
getMatrixSums([
[1, 1, 1],
[1, 1, 1],
[1, 1, 1]
]);
// [
// [3,3,3] // Horizontal sums
// [3,3,3] // Vertical sums
// ]
getMatrixSums([
[1, 1, 1]
]);
// [
// [3] // Horizontal sums
// [1,1,1] // Vertical sums
// ]
Tests
npm test
Contributing
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code.
Release History
- 1.1.0 Support for n !== m matrices
- 1.0.0 First release