Files
30-seconds-of-code/snippets/last-of-list.md
2017-12-10 17:59:07 +02:00

9 lines
97 B
Markdown

### Last of list
Return `arr.slice(-1)[0]`.
```js
var initial = arr => arr.slice(-1)[0];
}
```