3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function 3lettermonth($item){ return strlen($item) == 3; } $months = array('jan', 'feb', 'mar', 'apr'); array_push($months,'may'); $output = array_filter($months, "3lettermonth" ); print_r($output);
Output for 5.4.0 - 5.4.11
Parse error: syntax error, unexpected '3' (T_LNUMBER), expecting identifier (T_STRING) or '(' in nXOVr on line 3
Process exited with code 255.
Output for 5.3.0 - 5.3.21
Parse error: syntax error, unexpected T_LNUMBER, expecting T_STRING or '(' in nXOVr on line 3
Process exited with code 255.