array_summation
v1.0.5
Published
A package to calculate the sum of array items(numbers).
Readme
A regular Javascript function to find the sum of the array items(numbers only).
Note : Array items other than the number type gets converted to number zero(0).
- Code example :
import sum from "array_summation";
console.log(sum([1, 2, "amit", {lastname: "raj"}, true, 30, [], 100], 200));
- output = 333
