3v4l.org

run code in 300+ PHP versions simultaneously
<?php function square(&$n) { if(is_numeric($n)) $n = ($n * $n); } $array = array(0, 48, 22, 90, 44, 9, 222, 'Iamzheasshole', 101); array_walk($array, 'square'); print_r($array);

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.0070.00718.18
8.3.50.0120.00821.97
8.3.40.0140.00718.86
8.3.30.0110.00718.54
8.3.20.0040.00418.72
8.3.10.0040.00420.83
8.3.00.0070.00021.90
8.2.180.0180.00016.32
8.2.170.0100.00322.96
8.2.160.0100.00320.37
8.2.150.0080.00024.18
8.2.140.0090.00024.66
8.2.130.0040.00426.16
8.2.120.0040.00421.11
8.2.110.0090.00020.32
8.2.100.0080.00417.59
8.2.90.0080.00019.09
8.2.80.0000.00719.33
8.2.70.0040.00417.61
8.2.60.0040.00417.93
8.2.50.0000.00818.07
8.2.40.0000.00817.78
8.2.30.0040.00421.22
8.2.20.0000.00817.55
8.2.10.0080.00017.75
8.2.00.0040.00417.68
8.1.280.0000.01525.92
8.1.270.0000.00723.99
8.1.260.0110.00426.35
8.1.250.0040.00428.09
8.1.240.0060.00322.52
8.1.230.0070.00420.97
8.1.220.0040.00418.77
8.1.210.0050.00318.99
8.1.200.0100.00017.48
8.1.190.0070.00017.63
8.1.180.0050.00318.10
8.1.170.0080.00018.61
8.1.160.0040.00418.84
8.1.150.0040.00418.60
8.1.140.0000.00717.28
8.1.130.0030.00317.69
8.1.120.0040.00417.43
8.1.110.0080.00017.30
8.1.100.0000.00717.24
8.1.90.0040.00317.36
8.1.80.0000.00717.39
8.1.70.0000.00717.27
8.1.60.0030.00617.52
8.1.50.0040.00417.39
8.1.40.0050.00217.32
8.1.30.0080.00017.54
8.1.20.0090.00017.61
8.1.10.0030.00517.52
8.1.00.0090.00317.48
8.0.300.0080.00019.88
8.0.290.0040.00417.05
8.0.280.0070.00018.35
8.0.270.0040.00417.27
8.0.260.0060.00016.73
8.0.250.0070.00016.94
8.0.240.0020.00916.83
8.0.230.0000.00716.96
8.0.220.0070.00016.78
8.0.210.0000.00716.84
8.0.200.0040.00416.95
8.0.190.0040.00416.89
8.0.180.0040.00416.84
8.0.170.0040.00416.82
8.0.160.0030.00316.87
8.0.150.0000.00716.76
8.0.140.0050.00216.71
8.0.130.0060.00013.27
8.0.120.0030.00316.75
8.0.110.0040.00416.72
8.0.100.0000.00816.86
8.0.90.0080.00016.63
8.0.80.0070.00716.84
8.0.70.0040.00416.86
8.0.60.0040.00416.71
8.0.50.0040.00416.66
8.0.30.0110.00717.01
8.0.20.0110.00817.40
8.0.10.0050.00316.93
8.0.00.0100.00716.62
7.4.330.0020.00216.89
7.4.320.0000.00616.44
7.4.300.0000.00616.52
7.4.290.0030.00316.36
7.4.280.0000.00716.51
7.4.270.0070.00016.34
7.4.260.0000.00513.22
7.4.250.0000.00716.51
7.4.240.0000.00716.43
7.4.230.0070.00016.19
7.4.220.0030.01316.36
7.4.210.0090.00716.50
7.4.200.0000.00716.57
7.4.190.0040.00416.68
7.4.160.0060.01216.41
7.4.150.0170.00717.40
7.4.140.0090.00817.86
7.4.130.0090.01016.49
7.4.120.0080.01016.39
7.4.110.0030.01316.29
7.4.100.0130.00316.47
7.4.90.0000.02116.36
7.4.80.0060.01219.39
7.4.70.0120.00616.59
7.4.60.0130.00316.52
7.4.50.0000.00916.47
7.4.40.0100.01022.77
7.4.30.0060.00916.43
7.4.00.0120.00314.83
7.3.330.0060.00013.23
7.3.320.0000.00513.23
7.3.310.0000.00716.17
7.3.300.0030.00316.27
7.3.290.0060.01416.21
7.3.280.0070.00816.25
7.3.270.0100.00717.40
7.3.260.0080.01118.24
7.3.250.0180.00616.22
7.3.240.0100.00616.30
7.3.230.0070.01116.39
7.3.210.0060.01316.17
7.3.200.0070.01319.39
7.3.190.0130.00916.50
7.3.180.0080.00816.31
7.3.170.0140.00716.43
7.3.160.0030.01416.42
7.3.120.0070.01014.88
7.3.110.0110.00214.63
7.3.100.0030.00714.75
7.3.90.0110.00314.72
7.3.80.0000.01314.80
7.3.70.0030.00914.83
7.3.60.0030.00614.83
7.3.50.0070.00414.81
7.3.40.0030.01414.73
7.3.30.0110.00714.32
7.3.20.0080.00316.75
7.3.10.0000.00916.58
7.3.00.0060.00616.53
7.2.330.0070.01416.23
7.2.320.0030.01416.52
7.2.310.0160.02216.27
7.2.300.0120.00916.56
7.2.290.0070.01616.27
7.2.250.0060.00914.75
7.2.240.0070.01314.95
7.2.230.0000.01115.14
7.2.220.0040.00714.79
7.2.210.0060.00614.70
7.2.200.0040.00414.80
7.2.190.0030.00614.84
7.2.180.0060.00314.96
7.2.170.0040.00814.85
7.2.00.0040.01519.40
7.1.330.0090.00615.50
7.1.320.0030.00615.68
7.1.310.0030.01315.76
7.1.300.0060.00315.75
7.1.290.0030.01315.82
7.1.280.0070.00715.68
7.1.270.0070.00715.71
7.1.260.0070.00715.87
7.1.100.0030.00617.85
7.1.70.0000.00717.13
7.1.60.0070.01319.17
7.1.50.0040.01216.86
7.1.00.0000.07322.45
7.0.200.0330.00414.52
7.0.140.0100.06721.92
7.0.60.0070.06320.02
7.0.50.0030.08317.97
7.0.40.0000.08320.26
7.0.30.0370.08020.23
7.0.20.0370.07320.21
7.0.10.0170.03020.15
7.0.00.0100.07720.05
5.6.280.0070.07021.07
5.6.210.0070.03720.67
5.6.200.0130.08318.20
5.6.190.0030.07320.52
5.6.180.0130.04720.48
5.6.170.0270.04320.61
5.6.160.0130.07020.62
5.6.150.0100.07318.19
5.6.140.0000.04318.11
5.6.130.0070.07718.20
5.6.120.0000.06321.00
5.6.110.0070.04021.03
5.6.100.0100.06320.98
5.6.90.0070.06020.97
5.6.80.0000.04720.38
5.5.350.4200.04720.29
5.5.340.0030.08717.98
5.5.330.0100.03720.29
5.5.320.0130.04720.38
5.5.310.0270.07720.38
5.5.300.0030.05017.94
5.5.290.0100.08017.95
5.5.280.0170.07720.77
5.5.270.0070.04020.89
5.5.260.0070.08720.88
5.5.250.0170.06020.49
5.5.240.0000.06720.26
5.4.450.0230.03719.55
5.4.440.0170.04319.52
5.4.430.0100.04719.30
5.4.420.0130.04319.19
5.4.410.0170.04019.43
5.4.400.0400.03018.98
5.4.390.0230.04019.20
5.4.380.0200.03719.22
5.4.370.0200.05719.26
5.4.360.0170.04018.86
5.4.350.0170.03718.84
5.4.340.0200.03719.25
5.4.320.0170.03718.88
5.4.310.0230.06319.05
5.4.300.0370.03318.94
5.4.290.0130.06019.00
5.4.280.0170.06719.11
5.4.270.0230.05319.00
5.4.260.0230.05719.21
5.4.250.0130.07319.25
5.4.240.0230.04019.20
5.4.230.0270.04019.16
5.4.220.0170.04719.21
5.4.210.0270.05019.19
5.4.200.0370.04719.19
5.4.190.0230.07319.00
5.4.180.0170.04019.30
5.4.170.0170.04019.08
5.4.160.0200.03719.20
5.4.150.0170.04019.21
5.4.140.0230.05716.38
5.4.130.0130.04316.35
5.4.120.0200.07016.39
5.4.110.0170.03716.45
5.4.100.0230.04016.55
5.4.90.0370.05016.25
5.4.80.0300.03016.32
5.4.70.0300.06716.49
5.4.60.0230.07016.33
5.4.50.0300.05716.20
5.4.40.0200.05016.55
5.4.30.0370.05716.52
5.4.20.0300.06016.53
5.4.10.0300.07016.54
5.4.00.0270.04716.20
5.3.290.0230.05316.20
5.3.280.0270.04016.20
5.3.270.0330.07316.20
5.3.260.0270.05016.20
5.3.250.0270.04016.20
5.3.240.0270.07716.20
5.3.230.0300.03716.20
5.3.220.0330.06716.20
5.3.210.0270.04316.20
5.3.200.0200.04316.20
5.3.190.0170.04716.20
5.3.180.0170.04016.20
5.3.170.0200.03716.20
5.3.160.0270.03716.20
5.3.150.0270.07316.20
5.3.140.0230.03716.20
5.3.130.0230.03716.20
5.3.120.0200.05716.20
5.3.110.0170.04316.20
5.3.100.0070.04716.20
5.3.90.0170.04016.20
5.3.80.0270.06016.20
5.3.70.0170.04316.20
5.3.60.0170.04316.20
5.3.50.0170.04316.20
5.3.40.0100.05016.20
5.3.30.0200.04716.20
5.3.20.0230.06716.20
5.3.10.0130.04016.20
5.3.00.0270.05316.20
5.2.170.0130.06016.20
5.2.160.0200.03316.20
5.2.150.0230.03316.20
5.2.140.0170.03016.20
5.2.130.0200.05716.20
5.2.120.0170.03316.20
5.2.110.0200.03016.20
5.2.100.0270.02316.20
5.2.90.0170.04016.20
5.2.80.0200.06016.20
5.2.70.0130.04316.20
5.2.60.0200.02716.20
5.2.50.0130.05016.20
5.2.40.0100.03016.20
5.2.30.0070.03316.20
5.2.20.0130.02716.20
5.2.10.0130.02716.20
5.2.00.0100.03316.20
5.1.60.0130.02716.20
5.1.50.0130.02716.20
5.1.40.0200.03016.20
5.1.30.0170.02316.20
5.1.20.0100.03016.20
5.1.10.0170.02716.20
5.1.00.0170.02316.20
5.0.50.0070.02316.20
5.0.40.0070.02016.20
5.0.30.0070.03316.20
5.0.20.0130.04016.20
5.0.10.0130.02016.20
5.0.00.0070.05016.20
4.4.90.0070.01716.20
4.4.80.0030.01716.20
4.4.70.0030.02316.20
4.4.60.0070.01316.20
4.4.50.0030.01716.20
4.4.40.0070.03016.20
4.4.30.0070.03016.20
4.4.20.0030.01716.20
4.4.10.0070.02316.20
4.4.00.0070.02716.20
4.3.110.0100.02316.20
4.3.100.0100.01316.20
4.3.90.0100.02316.20
4.3.80.0070.03016.20
4.3.70.0200.02016.20
4.3.60.0100.01316.20
4.3.50.0100.01716.20
4.3.40.0070.02716.20
4.3.30.0030.01716.20
4.3.20.0070.02016.20
4.3.10.0030.03016.20
4.3.00.0070.02016.20

preferences:
62.97 ms | 401 KiB | 5 Q