3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function reducea($a1,$b1){ return $a1+$b1; } $arr =array("dog","cat","milk"); print_r(array_reduce($arr,"reducea"));
based on nrUcn
Output for 7.1.0
Warning: A non-numeric value encountered in /in/0ZtR5 on line 3 Warning: A non-numeric value encountered in /in/0ZtR5 on line 3 Warning: A non-numeric value encountered in /in/0ZtR5 on line 3 0
Output for 4.3.0 - 7.0.14
0