3v4l.org

run code in 300+ PHP versions simultaneously
<?php $my_key = uniqid("\x00"); if (preg_match('/[a-zA-Z]/', $my_key)) { echo "key has alpha chars\n"; } $var[$my_key] = TRUE; foreach($var as $key => $val) { if ($key === $my_key) { echo 'You got it right'; } else { echo 'You got it wrong'; } }

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.1.70.0060.00917.37
7.1.60.0070.01019.61
7.1.50.0040.01817.17
7.1.00.0100.07022.55
7.0.200.0060.00317.11
7.0.140.0030.07322.15
7.0.60.0070.03719.83
7.0.50.0070.08017.80
7.0.40.0100.08720.06
7.0.30.0300.07320.05
7.0.20.0370.08020.19
7.0.10.0070.08320.14
7.0.00.0070.05320.31
5.6.280.0070.07020.78
5.6.210.0070.06720.53
5.6.200.0100.05318.18
5.6.190.0070.06320.35
5.6.180.0200.04320.56
5.6.170.0230.08320.40
5.6.160.0070.04320.52
5.6.150.0100.03018.12
5.6.140.0130.07318.21
5.6.130.0030.04318.06
5.6.120.0030.05320.94
5.6.110.0070.08320.98
5.6.100.0100.06021.11
5.6.90.0130.08020.94
5.6.80.0030.04020.28
5.5.350.0270.07020.32
5.5.340.0070.08317.95
5.5.330.0100.06320.40
5.5.320.0270.04020.34
5.5.310.0230.08020.50
5.5.300.0070.06017.95
5.5.290.0030.08717.93
5.5.280.0170.07720.77
5.5.270.0100.08320.93
5.5.260.0130.07720.67
5.5.250.0170.06320.69
5.5.240.0130.06720.27
5.4.450.0170.04719.39
5.4.440.0300.04719.25
5.4.430.0270.04719.45
5.4.420.0300.04319.25
5.4.410.0470.03719.36
5.4.400.0500.03318.96
5.4.390.0330.05318.89
5.4.380.0330.07018.57
5.4.370.0430.04718.51
5.4.360.0270.05318.73
5.4.350.0400.04718.52
5.4.340.0330.06018.73
5.4.320.0080.03812.46
5.4.310.0050.03912.45
5.4.300.0070.03612.45
5.4.290.0070.03912.45
5.4.280.0090.03912.35
5.4.270.0100.05012.35
5.4.260.0130.04812.35
5.4.250.0090.04912.35
5.4.240.0180.06012.35
5.4.230.0140.04712.34
5.4.220.0140.04612.34
5.4.210.0130.04912.34
5.4.200.0070.05012.34
5.4.190.0080.03512.34
5.4.180.0080.04712.34
5.4.170.0090.04012.35
5.4.160.0070.05412.35
5.4.150.0110.04712.34
5.4.140.0070.05112.02
5.4.130.0090.04712.02
5.4.120.0070.05011.98
5.4.110.0060.03511.96
5.4.100.0110.03611.97
5.4.90.0050.04311.97
5.4.80.0100.03911.97
5.4.70.0050.03711.96
5.4.60.0040.03611.96
5.4.50.0040.03811.96
5.4.40.0030.03911.95
5.4.30.0110.04711.95
5.4.20.0100.04211.95
5.4.10.0080.04411.95
5.4.00.0080.04811.44
5.3.290.0080.03812.80
5.3.280.0090.05012.71
5.3.270.0050.04412.72
5.3.260.0130.04912.72
5.3.250.0110.04912.72
5.3.240.0080.05212.72
5.3.230.0080.05112.71
5.3.220.0130.04412.68
5.3.210.0080.05312.68
5.3.200.0050.03812.68
5.3.190.0080.03612.67
5.3.180.0090.03412.68
5.3.170.0070.03512.66
5.3.160.0060.03612.67
5.3.150.0050.03712.68
5.3.140.0050.03612.66
5.3.130.0080.03712.66
5.3.120.0110.03412.66
5.3.110.0070.04312.66
5.3.100.0060.04212.11
5.3.90.0090.04812.08
5.3.80.0070.03712.07
5.3.70.0040.03812.08
5.3.60.0050.03912.06
5.3.50.0060.04812.00
5.3.40.0130.05212.00
5.3.30.0110.04711.95
5.3.20.0110.04511.72
5.3.10.0100.04311.70
5.3.00.0110.04811.68
5.2.170.0050.0439.18
5.2.160.0070.0419.18
5.2.150.0130.0419.18
5.2.140.0070.0389.18
5.2.130.0120.0399.14
5.2.120.0050.0359.14
5.2.110.0130.0309.15
5.2.100.0060.0449.14
5.2.90.0090.0379.14
5.2.80.0100.0389.14
5.2.70.0060.0339.14
5.2.60.0070.0289.09
5.2.50.0070.0429.06
5.2.40.0070.0389.04
5.2.30.0060.0419.02
5.2.20.0080.0399.01
5.2.10.0070.0308.93
5.2.00.0110.0358.78
5.1.60.0040.0238.07
5.1.50.0050.0248.07
5.1.40.0070.0228.05
5.1.30.0060.0258.40
5.1.20.0060.0258.42
5.1.10.0040.0268.14
5.1.00.0050.0248.14
5.0.50.0030.0216.62
5.0.40.0050.0186.48
5.0.30.0060.0316.29
5.0.20.0020.0236.27
5.0.10.0040.0196.24
5.0.00.0030.0316.23
4.4.90.0030.0154.78
4.4.80.0010.0174.76
4.4.70.0050.0154.75
4.4.60.0060.0134.75
4.4.50.0060.0154.77
4.4.40.0030.0334.71
4.4.30.0050.0194.76
4.4.20.0020.0164.84
4.4.10.0030.0164.85
4.4.00.0050.0234.76
4.3.110.0040.0154.67
4.3.100.0060.0124.66
4.3.90.0030.0154.63
4.3.80.0040.0284.58
4.3.70.0000.0184.63
4.3.60.0070.0104.63
4.3.50.0010.0174.63
4.3.40.0010.0254.54
4.3.30.0000.0183.30
4.3.20.0000.0173.28
4.3.10.0020.0163.23
4.3.00.0030.01713.95

preferences:
33.29 ms | 401 KiB | 5 Q