3v4l.org

run code in 300+ PHP versions simultaneously
<?php $one = $two = $three = 0; for($i=0;$i<100;$i++) { $c = mt_rand(1,3); if($c == 1) { $one++; } elseif($c == 2) { $two++; } elseif($c=3) { $three++; } } echo "one {$one}; two {$two}; three {$three}";

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)
7.4.10.0040.01515.12
7.4.00.0090.00814.97
7.3.130.0120.00314.92
7.3.120.0080.00814.92
7.3.110.0080.00714.99
7.3.100.0050.00814.88
7.3.90.0050.00915.01
7.3.80.0040.00914.74
7.3.70.0070.00614.84
7.3.60.0060.00614.73
7.3.50.0040.01114.90
7.3.40.0020.00914.76
7.3.30.0060.00714.86
7.3.20.0050.01016.49
7.3.10.0050.01016.68
7.3.00.0040.00816.50
7.2.260.0040.01214.88
7.2.250.0090.01014.82
7.2.240.0050.01215.16
7.2.230.0080.00615.02
7.2.220.0080.00815.12
7.2.210.0060.00814.94
7.2.200.0080.00714.96
7.2.190.0100.00414.97
7.2.180.0030.01014.98
7.2.170.0020.01014.94
7.2.160.0030.01015.16
7.2.150.0110.00316.68
7.2.140.0060.00916.88
7.2.130.0100.00716.94
7.2.120.0040.01116.75
7.2.110.0110.00417.01
7.2.100.0060.00616.85
7.2.90.0060.00916.81
7.2.80.0070.00316.85
7.2.70.0110.00316.76
7.2.60.0130.00316.84
7.2.50.0030.00716.89
7.2.40.0120.00316.93
7.2.30.0120.00316.72
7.2.20.0120.00616.95
7.2.10.0040.01116.88
7.2.00.0030.01218.16
7.1.330.0060.00815.72
7.1.320.0070.00515.82
7.1.310.0050.00815.80
7.1.300.0060.00515.73
7.1.290.0060.00715.72
7.1.280.0030.01015.72
7.1.270.0050.00715.78
7.1.260.0070.00615.55
7.1.250.0000.01815.85
7.1.240.0000.00915.86
7.1.230.0030.01015.52
7.1.220.0000.01415.73
7.1.210.0060.00615.57
7.1.200.0080.00515.69
7.1.190.0030.01015.70
7.1.180.0040.00715.71
7.1.170.0030.01215.62
7.1.160.0000.01615.48
7.1.150.0030.01215.47
7.1.140.0060.00915.82
7.1.130.0030.00915.66
7.1.120.0100.00615.90
7.1.110.0040.01115.76
7.1.100.0000.01715.87
7.1.90.0030.01115.85
7.1.80.0000.01415.64
7.1.70.0050.00516.58
7.1.60.0040.01117.74
7.1.50.0100.00816.18
7.1.40.0080.00315.47
7.1.30.0110.00315.66
7.1.20.0150.00315.78
7.1.10.0070.00315.59
7.1.00.0030.04519.14
7.0.330.0070.01115.55
7.0.320.0040.01115.41
7.0.310.0030.01415.43
7.0.300.0030.00615.46
7.0.290.0000.00915.28
7.0.280.0120.00315.42
7.0.270.0050.00515.40
7.0.260.0070.00715.36
7.0.250.0100.00715.39
7.0.240.0030.00915.46
7.0.230.0040.01115.52
7.0.220.0040.01115.32
7.0.210.0040.01215.54
7.0.200.0150.00315.19
7.0.190.0040.00715.35
7.0.180.0040.01115.57
7.0.170.0030.01015.22
7.0.160.0110.00315.44
7.0.150.0000.00915.53
7.0.140.0020.04118.73
7.0.130.0070.00715.41
7.0.120.0060.01015.52
7.0.110.0070.01015.42
7.0.100.0110.00415.54
7.0.90.0070.00415.45
7.0.80.0000.01615.39
7.0.70.0030.00615.27
7.0.60.0100.03017.51
7.0.50.0020.04916.73
7.0.40.0070.02316.74
7.0.30.0230.04016.80
7.0.20.0120.04216.87
7.0.10.0100.03316.76
7.0.00.0090.03816.82
5.6.400.0060.00914.20
5.6.390.0080.00614.50
5.6.380.0040.01114.53
5.6.370.0000.00914.55
5.6.360.0040.01114.67
5.6.350.0030.00614.33
5.6.340.0100.00614.32
5.6.330.0080.00614.48
5.6.320.0060.00614.76
5.6.310.0080.00714.13
5.6.300.0070.00414.34
5.6.290.0060.00314.44
5.6.280.0080.03617.60
5.6.270.0040.01414.12
5.6.260.0090.00314.37
5.6.250.0090.00614.32
5.6.240.0070.00714.43
5.6.230.0070.00714.56
5.6.220.0060.00914.27
5.6.210.0030.02517.35
5.6.200.0080.04316.13
5.6.190.0050.03317.36
5.6.180.0240.04117.23
5.6.170.0210.04317.38
5.6.160.0020.03017.46
5.6.150.0100.03616.40
5.6.140.0080.04516.27
5.6.130.0030.03416.21
5.6.120.0100.04017.75
5.6.110.0130.03217.85
5.6.100.0030.04817.71
5.6.90.0100.03217.58
5.6.80.0020.03017.32
5.6.70.0060.00914.20
5.6.60.0160.00014.11
5.6.50.0050.00514.11
5.6.40.0030.01014.15
5.6.30.0030.00614.30
5.6.20.0090.00014.05
5.6.10.0000.01114.05
5.6.00.0040.00414.44
5.5.380.0040.00714.41
5.5.370.0030.01314.26
5.5.360.0140.00014.20
5.5.350.0100.03817.42
5.5.340.0120.03716.14
5.5.330.0060.04317.19
5.5.320.0230.04017.14
5.5.310.0120.03917.30
5.5.300.0030.02316.12
5.5.290.0060.02716.17
5.5.280.0030.02817.58
5.5.270.0130.04117.65
5.5.260.0100.04217.50
5.5.250.0030.02817.30
5.5.240.0130.04117.25
5.5.230.0040.00814.17
5.5.220.0000.00913.91
5.5.210.0030.01014.06
5.5.200.0000.01114.19
5.5.190.0060.00913.98
5.5.180.0040.01114.29
5.5.170.0000.00914.16
5.5.160.0030.01314.33
5.5.150.0070.00714.08
5.5.140.0030.01014.07
5.5.130.0030.01014.23
5.5.120.0070.00714.30
5.5.110.0090.00314.10
5.5.100.0040.00714.23
5.5.90.0070.00714.14
5.5.80.0030.01014.35
5.5.70.0070.00713.92
5.5.60.0030.00914.42
5.5.50.0070.01014.09
5.5.40.0000.01414.22
5.5.30.0100.00013.94
5.5.20.0090.00314.24
5.5.10.0050.00514.04
5.5.00.0030.00914.24
5.4.450.0100.03216.38
5.4.440.0260.02116.45
5.4.430.0300.02616.25
5.4.420.0280.02616.30
5.4.410.0180.02816.36
5.4.400.0230.02216.25
5.4.390.0180.02816.30
5.4.380.0180.02815.93
5.4.370.0130.03016.04
5.4.360.0200.03916.03
5.4.350.0250.03116.02
5.4.340.0130.03315.96
5.4.330.0080.00313.37
5.4.320.0050.02112.91
5.4.310.0050.02112.91
5.4.300.0060.01912.91
5.4.290.0040.02512.91
5.4.280.0080.01812.86
5.4.270.0060.01912.86
5.4.260.0020.02312.86
5.4.250.0020.02212.86
5.4.240.0050.02312.86
5.4.230.0060.02512.85
5.4.220.0070.01812.85
5.4.210.0050.02112.86
5.4.200.0040.02112.85
5.4.190.0030.02312.85
5.4.180.0070.02312.85
5.4.170.0060.02412.86
5.4.160.0060.02012.86
5.4.150.0070.01912.86
5.4.140.0080.01912.70
5.4.130.0040.02512.69
5.4.120.0080.01912.67
5.4.110.0070.02012.67
5.4.100.0040.02412.67
5.4.90.0050.02312.66
5.4.80.0050.02212.67
5.4.70.0030.02212.66
5.4.60.0050.01812.66
5.4.50.0090.01712.66
5.4.40.0040.02212.66
5.4.30.0040.02112.66
5.4.20.0070.02112.66
5.4.10.0020.02212.66
5.4.00.0080.01812.40
5.3.290.0060.03912.80
5.3.280.0030.04012.70
5.3.270.0110.03912.73
5.3.260.0040.04912.72
5.3.250.0040.03912.72
5.3.240.0050.03812.72
5.3.230.0090.03912.71
5.3.220.0080.04212.68
5.3.210.0050.03912.68
5.3.200.0030.03812.68
5.3.190.0110.03212.67
5.3.180.0070.03712.68
5.3.170.0070.03912.67
5.3.160.0070.03512.68
5.3.150.0060.04212.67
5.3.140.0040.03812.66
5.3.130.0050.03912.66
5.3.120.0060.03812.66
5.3.110.0060.03912.66
5.3.100.0060.03612.12
5.3.90.0060.03712.08
5.3.80.0060.03512.07
5.3.70.0040.03712.08
5.3.60.0050.03812.06
5.3.50.0100.03912.00
5.3.40.0060.04712.00
5.3.30.0090.03911.95
5.3.20.0040.03611.72
5.3.10.0070.03511.70
5.3.00.0120.03211.68
5.2.170.0030.0329.18
5.2.160.0040.0309.18
5.2.150.0100.0309.18
5.2.140.0080.0289.18
5.2.130.0090.0259.14
5.2.120.0060.0299.14
5.2.110.0030.0339.14
5.2.100.0020.0339.14
5.2.90.0040.0359.14
5.2.80.0090.0299.14
5.2.70.0040.0329.14
5.2.60.0070.0299.09
5.2.50.0030.0399.06
5.2.40.0050.0289.04
5.2.30.0060.0299.02
5.2.20.0050.0299.00
5.2.10.0040.0288.93
5.2.00.0050.0348.79
5.1.60.0030.0248.08
5.1.50.0040.0258.07
5.1.40.0060.0258.06
5.1.30.0040.0268.41
5.1.20.0060.0248.43
5.1.10.0040.0278.16
5.1.00.0090.0218.15
5.0.50.0070.0176.63
5.0.40.0030.0216.49
5.0.30.0020.0336.30
5.0.20.0030.0266.27
5.0.10.0060.0196.25
5.0.00.0030.0396.25
4.4.90.0040.0214.78
4.4.80.0020.0154.76
4.4.70.0030.0224.75
4.4.60.0020.0184.75
4.4.50.0080.0134.77
4.4.40.0010.0304.71
4.4.30.0030.0194.76
4.4.20.0020.0204.85
4.4.10.0050.0234.84
4.4.00.0030.0254.76
4.3.110.0010.0184.67
4.3.100.0030.0154.67
4.3.90.0030.0144.63
4.3.80.0050.0224.58
4.3.70.0030.0194.63
4.3.60.0020.0154.63
4.3.50.0010.0174.63
4.3.40.0020.0244.54
4.3.30.0020.0163.29
4.3.20.0020.0183.27
4.3.10.0020.0153.23
4.3.00.0030.01716.72

preferences:
44.61 ms | 401 KiB | 5 Q