Travis build: 559

This commit is contained in:
30secondsofcode
2018-09-29 13:47:39 +00:00
parent d1aaaf61aa
commit fd8ffcd2af
20 changed files with 194 additions and 20 deletions

View File

@ -6,7 +6,7 @@ Use `Array.prototype.reduce()` to calculate how many numbers are below the value
```js
const percentile = (arr, val) =>
100 * arr.reduce((acc, v) => acc + (v < val ? 1 : 0) + (v === val ? 0.5 : 0), 0) / arr.length;
(100 * arr.reduce((acc, v) => acc + (v < val ? 1 : 0) + (v === val ? 0.5 : 0), 0)) / arr.length;
```
```js