a guest Jul 19th, 2019 52 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
- let arr = [1,2,3,4,5];
- let sum = arr.reduce((previous, current) => current += previous);
- let avg = sum / arr.length;
RAW Paste Data