3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php /*$string="M"; $strig=""; $strg=""; $stg=""; $last=array($strig,$strg,$string,$stg); echo Implode($last,""); foreach ($last as $i=>$value){*/ $value='K'; switch($value) { case 'k': case 'K': echo "k"; break; case 'm': case 'M': echo "k"; break; default: echo "o"; endswitch;} //} ?>
Output for 5.4.0 - 5.4.21
Parse error: syntax error, unexpected 'endswitch' (T_ENDSWITCH), expecting case (T_CASE) or default (T_DEFAULT) or '}' in /in/T9v3k on line 22
Process exited with code 255.
Output for 5.3.0 - 5.3.27
Parse error: syntax error, unexpected T_ENDSWITCH, expecting T_CASE or T_DEFAULT or '}' in /in/T9v3k on line 22
Process exited with code 255.