mirror of
https://github.com/rjNemo/functional-programming-jargon
synced 2026-06-12 13:36:40 +00:00
commit
8235cd9832
1 changed files with 1 additions and 3 deletions
|
|
@ -108,9 +108,7 @@ executions with the the same input parameters.
|
||||||
Simplest functor in javascript is an `Array`
|
Simplest functor in javascript is an `Array`
|
||||||
|
|
||||||
```js
|
```js
|
||||||
[2,3,4].map( function(n) {
|
[2,3,4].map( n => n * 2 ); // [4,6,8]
|
||||||
return n + 2;
|
|
||||||
}); // [4,6,8]
|
|
||||||
```
|
```
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue