fork download
  1. <?php
  2.  
  3. $frutas = array('Maça', 'Banana', 'Perâ', 'Morango');
  4.  
  5. $funcao = function($fruta) {
  6. echo $fruta . "\n";
  7. };
  8.  
  9. array_map($funcao, $frutas);
Success #stdin #stdout 0.02s 24400KB
stdin
Standard input is empty
stdout
Maça
Banana
Perâ
Morango