3v4l.org

run code in 300+ PHP versions simultaneously
<?php ini_set('display_errors', true); ini_set('error_reporting', E_ALL); $a = 4; switch ($a) { case 1: echo __LINE__; break; default: case 2: echo __LINE__; break; default: case 3: echo __LINE__; break; } echo "\ndone\n";
Output for 7.0.0 - 7.0.2
Fatal error: Switch statements may only contain one default clause in /in/TYnqD on line 13
Process exited with code 255.
Output for 5.5.24 - 5.5.35, 5.6.8 - 5.6.28
14 done

preferences:
162.2 ms | 1399 KiB | 37 Q