3v4l.org

run code in 300+ PHP versions simultaneously
<?php function test () { try { $a = 1; throw new \Exception('test'); echo 'try'; return $a; } catch (\Exception $e) { $a = 2; return $a; } finally { return $a; } } var_dump(test());

preferences:
26.26 ms | 404 KiB | 5 Q