3v4l.org

run code in 300+ PHP versions simultaneously
<?php function test(array $array) { try { return isDictionary($array); } catch (Exception $e) { echo 'ss'; return 'error'; } } function isDictionary($array) { foreach($array as $key => $value) { return ! is_int($key); } return false; } $arr = 0; var_dump(test($arr));

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.0130.01316.75
8.3.50.0150.00521.92
8.3.40.0100.01018.80
8.3.30.0090.00618.84
8.3.20.0000.00820.34
8.3.10.0040.00423.49
8.3.00.0080.00019.38
8.2.180.0140.00718.28
8.2.170.0070.00722.96
8.2.160.0160.00020.32
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0090.00017.63
8.2.120.0040.00426.35
8.2.110.0060.00320.25
8.2.100.0040.00817.72
8.2.90.0040.00418.93
8.2.80.0040.00417.97
8.2.70.0060.00317.50
8.2.60.0050.00517.80
8.2.50.0050.00318.07
8.2.40.0040.00419.43
8.2.30.0040.00420.59
8.2.20.0040.00417.60
8.2.10.0080.00317.98
8.2.00.0000.00718.06
8.1.280.0160.00025.92
8.1.270.0000.00923.84
8.1.260.0050.00228.09
8.1.250.0040.00428.09
8.1.240.0040.00423.68
8.1.230.0040.00822.07
8.1.220.0000.01217.74
8.1.210.0000.00918.77
8.1.200.0030.00617.48
8.1.190.0050.00317.10
8.1.180.0050.00318.10
8.1.170.0040.00418.78
8.1.160.0040.00421.86
8.1.150.0080.00018.75
8.1.140.0030.00519.52
8.1.130.0030.00317.63
8.1.120.0030.00517.45
8.1.110.0040.00417.41
8.1.100.0040.00417.43
8.1.90.0000.00817.41
8.1.80.0040.00417.36
8.1.70.0070.00017.43
8.1.60.0060.00317.54
8.1.50.0000.00817.54
8.1.40.0080.00017.48
8.1.30.0000.00817.63
8.1.20.0000.00817.61
8.1.10.0000.00817.55
8.1.00.0040.00417.52
8.0.300.0040.00418.77
8.0.290.0060.00316.63
8.0.280.0070.00018.34
8.0.270.0080.00017.25
8.0.260.0030.00317.25
8.0.250.0030.00316.87
8.0.240.0070.00016.93
8.0.230.0070.00316.95
8.0.220.0040.00416.82
8.0.210.0030.00616.80
8.0.200.0000.00816.82
8.0.190.0030.00316.91
8.0.180.0050.00216.95
8.0.170.0040.00416.98
8.0.160.0050.00216.89
8.0.150.0040.00416.75
8.0.140.0030.00316.72
8.0.130.0030.00313.32
8.0.120.0040.00416.82
8.0.110.0040.00416.72
8.0.100.0070.00016.71
8.0.90.0000.00816.84
8.0.80.0130.00716.78
8.0.70.0070.00016.85
8.0.60.0040.00416.84
8.0.50.0040.00416.92
8.0.30.0110.00717.08
8.0.20.0130.00517.40
8.0.10.0000.00816.84
8.0.00.0090.00816.77
7.4.330.0030.00315.08
7.4.320.0000.00616.46
7.4.300.0060.00016.59
7.4.290.0030.00316.58
7.4.280.0000.00716.51
7.4.270.0000.00616.52
7.4.260.0030.00316.63
7.4.250.0040.00416.41
7.4.240.0050.00216.50
7.4.230.0000.00716.60
7.4.220.0100.01316.71
7.4.210.0080.00816.63
7.4.200.0070.00016.68
7.4.160.0170.00016.51
7.4.150.0140.00417.40
7.4.140.0070.01017.86
7.4.130.0050.01516.55
7.4.120.0080.00916.41
7.4.110.0200.00316.34
7.4.100.0140.00616.66
7.4.90.0060.01616.59
7.4.80.0150.00819.39
7.4.70.0090.00916.54
7.4.60.0060.01016.27
7.4.50.0030.01316.21
7.4.40.0170.00016.36
7.4.30.0100.00716.38
7.4.00.0100.00714.98
7.3.330.0020.00513.30
7.3.320.0030.00313.21
7.3.310.0030.00316.29
7.3.300.0040.00416.32
7.3.290.0090.00716.27
7.3.280.0060.01116.28
7.3.270.0140.00317.40
7.3.260.0140.00316.34
7.3.250.0130.00416.44
7.3.240.0150.00516.39
7.3.230.0060.01016.55
7.3.210.0070.01016.31
7.3.200.0140.00316.29
7.3.190.0030.01416.45
7.3.180.0000.01616.39
7.3.170.0100.00716.32
7.3.160.0130.00316.36
7.3.120.0100.00714.54
7.3.110.0080.00814.87
7.3.100.0000.01714.53
7.3.90.0060.00614.97
7.3.80.0030.01014.75
7.3.70.0100.00614.87
7.3.60.0000.01314.82
7.3.50.0040.01114.73
7.3.40.0000.00814.85
7.3.30.0030.01014.59
7.3.20.0110.00316.69
7.3.10.0080.00316.73
7.3.00.0090.00316.63
7.2.330.0100.01016.57
7.2.320.0180.00016.56
7.2.310.0110.00616.48
7.2.300.0060.01316.57
7.2.290.0070.01016.40
7.2.250.0060.01215.01
7.2.240.0070.00714.87
7.2.230.0030.00915.11
7.2.220.0000.01514.86
7.2.210.0000.00915.05
7.2.200.0110.00314.85
7.2.190.0040.01115.04
7.2.180.0060.00314.83
7.2.170.0060.00314.90
7.2.160.0040.00814.63
7.2.150.0030.00616.59
7.2.140.0080.00417.01
7.2.130.0090.00016.51
7.2.120.0000.00816.74
7.2.110.0050.00516.88
7.2.100.0000.01316.58
7.2.90.0100.00616.85
7.2.80.0070.00716.90
7.2.70.0070.01016.90
7.2.60.0090.00516.63
7.2.50.0040.00416.82
7.2.40.0030.01016.75
7.2.30.0080.00316.82
7.2.20.0070.00716.83
7.2.10.0030.01316.56
7.2.00.0050.00617.84
7.1.330.0030.01415.61
7.1.320.0030.00715.73
7.1.310.0030.01015.78
7.1.300.0120.00315.54
7.1.290.0060.00315.61
7.1.280.0070.00315.88
7.1.270.0030.00715.85
7.1.260.0030.01315.66
7.1.250.0000.00915.92
7.1.200.0060.00315.43
7.1.100.0000.01118.18
7.1.70.0040.00417.13
7.1.60.0060.01819.36
7.1.50.0100.01416.63
7.1.00.0000.08022.43
7.0.200.0060.00316.67
7.0.60.0000.04319.94
7.0.50.0070.07317.97
7.0.40.0070.07320.27
7.0.30.0400.07020.09
7.0.20.0200.06020.09
7.0.10.0100.05720.12
7.0.00.0070.04320.34
5.6.280.0070.05720.86
5.6.210.0070.04020.63
5.6.200.0130.08318.14
5.6.190.0070.05020.64
5.6.180.4070.03720.46
5.6.170.0230.04020.44
5.6.160.0100.08020.54
5.6.150.0000.04018.28
5.6.140.0000.04318.24
5.6.130.0100.04318.18
5.6.120.0070.08321.13
5.6.110.0070.08321.01
5.6.100.0230.07720.96
5.6.90.0170.07320.98
5.6.80.0100.07720.44
5.5.350.3500.04020.43
5.5.340.0030.08318.09
5.5.330.0030.04320.43
5.5.320.0030.08320.27
5.5.310.0200.04720.35
5.5.300.0130.07317.95
5.5.290.0100.03317.95
5.5.280.0000.04320.89
5.5.270.0070.04320.97
5.5.260.0030.07320.86
5.5.250.0130.06720.68
5.5.240.0130.06020.07

preferences:
99.31 ms | 401 KiB | 5 Q