Skip to content

Instantly share code, notes, and snippets.

@lukaszkorecki
Last active August 12, 2016 13:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lukaszkorecki/3238021538bf7a6a7da2b56e406d5727 to your computer and use it in GitHub Desktop.
Save lukaszkorecki/3238021538bf7a6a7da2b56e406d5727 to your computer and use it in GitHub Desktop.
function add1(arg) {
return arg + 1;
}
function sub2(arg) {
return arg - 2
}
function add1ToColl(coll) {
return coll.prototype.map.curry(add1);
}
function remove2FromColl(coll) {
return coll.prototype.map.curry(sub2);
}
add1ToColl(remove2FromColl([1,2,3])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment