3v4l.org

run code in 300+ PHP versions simultaneously
<?php declare(strict_types=1); $input = '0'; switch ($input) { case 0: $result = "hello "; break; case '1': case '2': case '0': $result = "world"; break; default: $result = "not found"; } echo $result; $result = match($input){ 0 => "hello ", '1', '2', '0' => "world", default => 'not found' }; echo $result ;

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
8.3.60.0120.00618.28
8.3.50.0070.01016.14
8.3.40.0100.00421.78
8.3.30.0050.01018.35
8.3.20.0080.00024.18
8.3.10.0080.00024.66
8.3.00.0040.00426.16
8.2.180.0100.00325.92
8.2.170.0070.00718.96
8.2.160.0130.00322.96
8.2.150.0080.00025.66
8.2.140.0050.00324.66
8.2.130.0040.00426.16
8.2.120.0000.00726.35
8.2.110.0060.00320.35
8.2.100.0100.00020.94
8.1.280.0000.01725.92
8.1.270.0040.00423.99
8.1.260.0100.00328.09
8.1.250.0060.00328.09
8.1.240.0030.00618.93
8.1.230.0030.00618.88
7.4.120.0040.01416.28
7.4.110.0070.01016.50
7.4.100.0030.01316.57
7.4.90.0180.00016.54
7.4.80.0120.00616.20
7.4.70.0070.01116.54
7.4.60.0070.01016.30
7.4.50.0110.00716.39
7.4.40.0110.00616.47
7.4.30.0070.01016.11
7.4.20.0100.00716.19
7.4.10.0100.00716.13
7.4.00.0140.00416.32
7.3.240.0070.01016.16
7.3.230.0130.00416.37
7.3.220.0100.00616.55
7.3.210.0070.01016.35
7.3.200.0060.01216.02
7.3.190.0070.01016.20
7.3.180.0060.01116.17
7.3.170.0150.00016.19
7.3.160.0160.00016.23
7.3.150.0090.00816.11
7.3.140.0030.01316.04
7.3.130.0100.00616.38
7.3.120.0090.00916.17
7.3.110.0060.01216.00
7.3.100.0370.02516.11
7.3.90.0080.01416.23
7.3.80.0060.01216.26
7.3.70.0080.00816.27
7.3.60.0000.01716.09
7.3.50.0040.01216.29
7.3.40.0100.00716.13
7.3.30.0100.00716.31
7.3.20.0070.01016.33
7.3.10.0070.01016.14
7.3.00.0030.01316.05
7.2.340.0100.00616.40
7.2.330.0100.00716.32
7.2.320.0100.00716.34
7.2.310.0150.00316.26
7.2.300.0120.00416.54
7.2.290.0030.01416.43
7.2.280.0210.00016.05
7.2.270.0160.00316.46
7.2.260.0130.00316.05
7.2.250.0130.00316.13
7.2.240.0070.01116.28
7.2.230.0120.00916.16
7.2.220.0130.00316.25
7.2.210.0100.00716.26
7.2.200.0070.01116.16
7.2.190.0090.00916.32
7.2.180.0110.00516.26
7.2.170.0100.00816.44
7.2.160.0120.00616.11
7.2.150.0070.01016.13
7.2.140.0070.01116.43
7.2.130.0160.00616.42
7.2.120.0070.01116.36
7.2.110.0140.00316.46
7.2.100.0110.00716.37
7.2.90.0060.01216.43
7.2.80.0060.01216.36
7.2.70.0130.00316.46
7.2.60.0170.00316.33
7.2.50.0130.00316.50
7.2.40.0130.00316.38
7.2.30.0120.00616.38
7.2.20.0120.00516.36
7.2.10.0130.00316.28
7.2.00.0080.01116.23

preferences:
48.15 ms | 400 KiB | 5 Q