3v4l.org

run code in 300+ PHP versions simultaneously
<?php $s = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"; $len = strlen($s); $m = ''; for ($i = 0; $i < $len; $i ++) { $m = $s[mt_rand(0, $len -1)]; } return $m;

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.0100.00714.91
7.4.00.0070.01114.89
7.3.130.0070.01014.99
7.3.120.0070.01014.95
7.3.110.0100.00614.64
7.3.100.0100.00714.79
7.3.90.0070.00714.80
7.3.80.0070.00714.81
7.3.70.0030.00614.86
7.3.60.0030.01314.90
7.3.50.0040.01114.55
7.3.40.0070.01014.73
7.3.30.0080.00014.56
7.3.20.0030.01016.70
7.3.10.0050.01016.27
7.3.00.0020.00816.28
7.2.260.0090.00915.29
7.2.250.0040.01215.20
7.2.240.0140.00314.78
7.2.230.0080.00414.89
7.2.220.0070.00715.21
7.2.210.0030.01015.24
7.2.200.0030.00715.11
7.2.190.0040.00815.21
7.2.180.0100.00715.14
7.2.170.0030.01015.30
7.2.160.0030.01315.09
7.2.150.0030.00816.84
7.2.140.0100.00616.86
7.2.130.0070.00716.89
7.2.120.0060.00716.77
7.2.110.0040.01216.84
7.2.100.0080.00716.76
7.2.90.0050.00916.67
7.2.80.0040.00916.60
7.2.70.0030.00916.99
7.2.60.0050.01016.98
7.2.50.0060.00716.62
7.2.40.0100.00316.95
7.2.30.0060.00716.93
7.2.20.0090.00316.94
7.2.10.0020.01116.82
7.2.00.0030.00917.08
7.1.330.0100.00316.04
7.1.320.0060.00615.80
7.1.310.0030.01015.63
7.1.300.0070.01015.91
7.1.290.0070.01115.79
7.1.280.0030.00816.06
7.1.270.0000.01315.66
7.1.260.0030.01315.86
7.1.250.0030.00815.60
7.1.240.0030.01015.59
7.1.230.0030.01215.67
7.1.220.0070.01015.89
7.1.210.0040.01115.84
7.1.200.0030.00715.94
7.1.190.0060.01015.89
7.1.180.0120.00015.70
7.1.170.0030.00915.97
7.1.160.0000.01715.78
7.1.150.0060.00915.91
7.1.140.0100.00315.82
7.1.130.0060.00615.70
7.1.120.0040.00815.77
7.1.110.0070.00715.64
7.1.100.0110.00315.85
7.1.90.0030.01015.86
7.1.80.0030.00615.72
7.1.70.0070.00516.36
7.1.60.0050.00616.46
7.1.50.0020.01416.46
7.1.40.0000.01115.84
7.1.30.0040.01115.90
7.1.20.0040.01115.79
7.1.10.0060.00615.64
7.1.00.0060.02119.14
7.0.330.0080.00415.50
7.0.320.0030.00615.36
7.0.310.0070.00715.02
7.0.300.0030.00615.45
7.0.290.0040.00815.38
7.0.280.0040.01215.17
7.0.270.0030.01015.41
7.0.260.0030.01015.20
7.0.250.0070.00715.31
7.0.240.0070.00715.59
7.0.230.0040.01115.64
7.0.220.0030.00815.46
7.0.210.0070.00715.42
7.0.200.0050.01116.18
7.0.190.0030.01015.55
7.0.180.0030.01015.51
7.0.170.0110.00415.39
7.0.160.0030.01015.47
7.0.150.0080.00615.40
7.0.140.0050.03718.70
7.0.130.0100.00315.50
7.0.120.0090.00315.24
7.0.110.0000.00815.46
7.0.100.0050.02517.71
7.0.90.0120.03817.67
7.0.80.0060.04317.77
7.0.70.0280.03017.77
7.0.60.0240.03617.74
7.0.50.0220.04117.85
7.0.40.0080.04316.81
7.0.30.0080.04216.82
7.0.20.0070.03416.75
7.0.10.0050.04416.83
7.0.00.0050.04016.80
5.6.400.0070.00714.57
5.6.390.0040.00814.34
5.6.380.0090.00614.45
5.6.370.0030.00914.59
5.6.360.0030.01314.44
5.6.350.0030.01114.23
5.6.340.0000.01514.65
5.6.330.0030.01214.14
5.6.320.0060.00614.29
5.6.310.0000.01114.66
5.6.300.0070.01014.38
5.6.290.0080.00414.55
5.6.280.0080.03617.88
5.6.270.0090.00614.35
5.6.260.0030.01314.29
5.6.250.0030.02817.48
5.6.240.0070.04617.51
5.6.230.0070.04517.56
5.6.220.0070.03017.39
5.6.210.0000.05017.47
5.6.200.0070.04317.68
5.6.190.0100.04217.64
5.6.180.0080.04017.75
5.6.170.0060.04617.89
5.6.160.0080.03117.62
5.6.150.0050.02617.64
5.6.140.0080.04217.62
5.6.130.0050.04217.86
5.6.120.0040.03617.80
5.6.110.0100.04617.70
5.6.100.0050.04217.79
5.6.90.0120.03417.54
5.6.80.0050.04217.39
5.6.70.0040.03017.34
5.6.60.0030.03717.36
5.6.50.0070.04217.36
5.6.40.0050.04317.29
5.6.30.0070.04517.25
5.6.20.0070.03417.29
5.6.10.0070.02517.38
5.6.00.0060.03817.19
5.5.380.0120.02517.40
5.5.370.0110.03817.39
5.5.360.0100.03817.39
5.5.350.0110.04217.29
5.5.340.0120.03817.50
5.5.330.0030.02717.58
5.5.320.0050.04717.50
5.5.310.0070.02517.60
5.5.300.0080.04217.48
5.5.290.0030.03217.56
5.5.280.0070.04517.55
5.5.270.0050.04717.43
5.5.260.0080.03617.53
5.5.250.0050.04017.42
5.5.240.0080.03217.16
5.5.230.0050.02817.16
5.5.220.0100.03817.16
5.5.210.0060.02317.11
5.5.200.0000.04517.35
5.5.190.0070.02717.15
5.5.180.0080.04417.11
5.5.170.0070.00714.13
5.5.160.0050.04617.18
5.5.150.0120.02217.34
5.5.140.0070.04217.33
5.5.130.0060.02617.35
5.5.120.0060.02817.17
5.5.110.0120.03517.11
5.5.100.0030.04517.18
5.5.90.0110.02817.14
5.5.80.0080.03217.23
5.5.70.0100.03817.19
5.5.60.0110.03617.21
5.5.50.0080.04116.92
5.5.40.0030.02917.27
5.5.30.0070.03917.20
5.5.20.0070.03017.23
5.5.10.0080.03517.07
5.5.00.0080.03617.23
5.4.450.0050.04615.93
5.4.440.0080.03815.98
5.4.430.0080.03716.01
5.4.420.0050.04016.01
5.4.410.0030.03015.87
5.4.400.0050.02515.69
5.4.390.0070.02315.81
5.4.380.0080.03315.84
5.4.370.0070.02115.91
5.4.360.0030.04515.83
5.4.350.0090.03515.86
5.4.340.0070.03815.87
5.4.330.0030.00612.60
5.4.320.0020.02715.82
5.4.310.0090.03915.86
5.4.300.0080.02815.86
5.4.290.0030.03415.83
5.4.280.0050.03815.83
5.4.270.0070.02415.81
5.4.260.0080.03615.88
5.4.250.0090.03815.75
5.4.240.0030.04415.84
5.4.230.0050.03615.85
5.4.220.0060.04615.85
5.4.210.0090.03315.80
5.4.200.0070.03915.91
5.4.190.0030.02415.71
5.4.180.0050.04215.75
5.4.170.0030.04115.83
5.4.160.0100.03715.74
5.4.150.0050.03215.85
5.4.140.0020.04614.44
5.4.130.0050.04014.43
5.4.120.0020.04314.44
5.4.110.0030.03214.47
5.4.100.0050.04414.40
5.4.90.0050.04014.45
5.4.80.0060.03814.47
5.4.70.0050.03514.47
5.4.60.0020.02914.50
5.4.50.0070.04014.40
5.4.40.0080.02314.47
5.4.30.0100.02914.40
5.4.20.0070.02814.45
5.4.10.0030.04014.45
5.4.00.0050.04014.08
5.3.290.0050.03713.56
5.3.280.0060.02813.52
5.3.270.0030.02713.52
5.3.260.0110.03113.56
5.3.250.0080.03813.53
5.3.240.0080.03013.53
5.3.230.0050.04613.59
5.3.220.0030.04213.51
5.3.210.0080.03713.59
5.3.200.0030.04513.52
5.3.190.0080.03513.56
5.3.180.0070.03013.53
5.3.170.0070.03313.56
5.3.160.0030.02813.55
5.3.150.0050.04013.50
5.3.140.0070.02613.55
5.3.130.0050.03613.56
5.3.120.0030.04313.55
5.3.110.0050.04313.50
5.3.100.0050.03013.31
5.3.90.0050.03713.29
5.3.80.0030.04213.24
5.3.70.0050.02813.31
5.3.60.0050.04113.29
5.3.50.0060.03913.18
5.3.40.0090.01813.28
5.3.30.0090.02613.26
5.3.20.0030.03713.13
5.3.10.0050.03713.13
5.3.00.0080.02313.11
5.2.170.0000.03312.30
5.2.160.0070.05712.30
5.2.150.0070.04312.30
5.2.140.0070.05712.30
5.2.130.0070.04312.30
5.2.120.0070.05012.30
5.2.110.0030.04012.30
5.2.100.0130.04712.30
5.2.90.0070.05712.30
5.2.80.0100.05312.30
5.2.70.0030.07312.30
5.2.60.0070.04012.30
5.2.50.0100.06312.30
5.2.40.0070.04712.30
5.2.30.0030.03312.30
5.2.20.0100.05312.30
5.2.10.0030.03012.30
5.2.00.0100.05012.30
5.1.60.0030.05012.30
5.1.50.0100.05012.30
5.1.40.0000.05712.30
5.1.30.0000.05712.30
5.1.20.0030.05012.30
5.1.10.0100.05312.30
5.1.00.0070.04712.30
5.0.50.0030.04312.30
5.0.40.0030.04312.30
5.0.30.0070.05312.30
5.0.20.0100.03312.30
5.0.10.0030.03712.30
5.0.00.0030.03312.30
4.4.90.0100.03012.30
4.4.80.0070.01312.30
4.4.70.0000.03712.30
4.4.60.0030.03312.30
4.4.50.0000.03312.30
4.4.40.0070.02712.30
4.4.30.0030.03712.30
4.4.20.0000.03012.30
4.4.10.0000.03312.30
4.4.00.0000.03712.30
4.3.110.0000.02312.30
4.3.100.0070.01712.30
4.3.90.0000.03312.30
4.3.80.0030.04712.30
4.3.70.0030.02712.30
4.3.60.0070.02312.30
4.3.50.0030.02012.30
4.3.40.0000.05012.30
4.3.30.0030.03312.30
4.3.20.0000.02712.30
4.3.10.0030.02012.30
4.3.00.0000.02312.30

preferences:
45.53 ms | 400 KiB | 5 Q