Merge pull request #52 from neighborhood999/patch-1

use `let` instead of `var` in for loop.
This commit is contained in:
hemanth.hm 2016-06-19 19:02:05 +05:30 committed by GitHub
commit 9397e16816

View file

@ -66,7 +66,7 @@ A function which takes a function as an argument and/or returns a function.
```js
const filter = (pred, xs) => {
const result = [];
for (var idx = 0; idx < xs.length; idx++) {
for (let idx = 0; idx < xs.length; idx++) {
if (pred(xs[idx])) {
result.push(xs[idx]);
}