Updated tools, proper linting, build README

This commit is contained in:
Angelos Chalaris
2017-12-14 19:38:11 +02:00
parent 0a2175e00e
commit e0693339b4
13 changed files with 74 additions and 61 deletions

View File

@ -4,9 +4,9 @@ Loop through the array, using `Array.shift()` to drop the first element of the a
Returns the remaining elements.
```js
const dropElements = (arr,func) => {
while(arr.length > 0 && !func(arr[0])) arr.shift();
const dropElements = (arr, func) => {
while (arr.length > 0 && !func(arr[0])) arr.shift();
return arr;
}
};
// dropElements([1, 2, 3, 4], n => n >= 3) -> [3,4]
```