Skip to content

Instantly share code, notes, and snippets.

@williamokano
Created May 4, 2019 01:14
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 williamokano/0083fc7bec2503f1ad26f8ff63661626 to your computer and use it in GitHub Desktop.
Save williamokano/0083fc7bec2503f1ad26f8ff63661626 to your computer and use it in GitHub Desktop.
<?php
$items = [1, 2, 3];
$multiplier = 2;
$doubledItems = array_map(function ($item) use ($multiplier) {
return $item * $multiplier;
}, $items);
@joomoraes
Copy link

joomoraes commented May 23, 2022

Estou lendo seu artigo, achei bastante interessante o fato de sair um pouco do POO e ir para a Programação Orientada a Eventos.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment