3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { protected static function bar($arg) { return $arg * 1; } public static function test() { $foo = 'e'; switch ($foo) { case 'a': $b = 1; break; case 'b': $b = 2; break; case 'c': $b = 3; break; case 'd': $b = 4; break; case 'e': $b = 5; break; } var_dump($b); } } Foo::test();

preferences:
27.78 ms | 402 KiB | 5 Q