3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $array = array( 'A' => array(1, 2, 3, 4), 'B' => array(5, 6), 'C' => array('a', 'b', 'c')); $values=""; $val = array(); function makeCombinations($array,$values){ foreach($array as $value) { if(is_array($value)) makeCombinations($value,$values); else $val[]=$value; } } makeCombinations($array,$values); print_r($val); //echo $values;
Output for 4.3.0 - 5.0.5, 5.1.1 - 7.1.0
Array ( )
Output for 5.1.0
Fatal error: fatal flex scanner internal error--end of buffer missed in /in/1CD0o on line 16
Process exited with code 255.