Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Artigo - Introdução a programação funcional com JavaScript - Exemplo 1
let numbers = [1, 5, 10];
const doubleValue = x => x * 2;
console.log(numbers.map(doubleValue)); // [2, 10, 20]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.