3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str[] = "3543900000133243"; $str[] = "3543sssssxxxxxx23243"; $str[] = "1543344=-23-1--923243"; $pattern = "/\A3543(.+)3243\Z/"; foreach($str as $key=>$string) { if(preg_match($pattern,$string,$res)) { echo "found in $string: ".$res[1]." at position ".strpos($string,$res[1]); } else { echo "not found in $string"; } }

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.0140.00718.68
8.3.50.0100.00821.97
8.3.40.0070.00719.14
8.3.30.0110.00718.93
8.3.20.0090.00018.86
8.3.10.0040.00420.88
8.3.00.0050.00323.66
8.2.180.0120.00316.75
8.2.170.0080.00622.96
8.2.160.0100.00320.54
8.2.150.0060.00324.18
8.2.140.0080.00024.66
8.2.130.0070.00026.16
8.2.120.0040.00421.13
8.2.110.0110.01120.57
8.2.100.0060.00617.97
8.2.90.0040.00419.34
8.2.80.0030.00518.04
8.2.70.0030.00617.88
8.2.60.0030.00618.05
8.2.50.0000.00818.07
8.2.40.0030.00518.22
8.2.30.0000.00721.29
8.2.20.0080.00017.88
8.2.10.0040.00417.87
8.2.00.0080.00017.93
8.1.280.0150.00025.92
8.1.270.0040.00424.66
8.1.260.0000.00726.35
8.1.250.0050.00328.09
8.1.240.0030.00722.46
8.1.230.0110.00020.89
8.1.220.0040.00418.77
8.1.210.0050.00318.95
8.1.200.0060.00317.48
8.1.190.0040.00417.53
8.1.180.0080.00018.10
8.1.170.0060.00318.72
8.1.160.0000.00919.01
8.1.150.0040.00418.86
8.1.140.0030.00617.55
8.1.130.0040.00417.88
8.1.120.0070.00017.65
8.1.110.0000.00717.66
8.1.100.0070.00017.63
8.1.90.0000.00717.55
8.1.80.0070.00017.66
8.1.70.0030.00317.52
8.1.60.0040.00417.77
8.1.50.0000.00817.64
8.1.40.0020.00517.71
8.1.30.0030.00517.81
8.1.20.0030.00517.83
8.1.10.0000.00817.79
8.1.00.0000.00717.72
8.0.300.0030.00619.97
8.0.290.0000.00717.05
8.0.280.0000.00818.53
8.0.270.0070.00017.30
8.0.260.0030.00316.99
8.0.250.0000.00817.12
8.0.240.0040.00417.16
8.0.230.0050.00317.13
8.0.220.0040.00416.98
8.0.210.0000.00716.97
8.0.200.0080.00316.98
8.0.190.0000.00917.01
8.0.180.0040.00417.12
8.0.170.0040.00417.06
8.0.160.0040.00416.96
8.0.150.0030.00316.91
8.0.140.0000.00817.05
8.0.130.0050.00013.50
8.0.120.0030.00517.04
8.0.110.0020.00516.99
8.0.100.0040.00417.00
8.0.90.0040.00417.01
8.0.80.0110.00617.07
8.0.70.0040.00417.04
8.0.60.0000.00716.91
8.0.50.0030.00617.13
8.0.30.0110.01117.24
8.0.20.0090.00917.48
8.0.10.0070.00017.19
8.0.00.0100.00716.89
7.4.330.0050.00014.94
7.4.320.0030.00316.84
7.4.300.0030.00316.75
7.4.290.0000.00716.82
7.4.280.0040.00416.63
7.4.270.0040.00416.82
7.4.260.0030.00313.45
7.4.250.0050.00316.84
7.4.240.0070.00016.84
7.4.230.0030.00316.53
7.4.220.0100.01016.73
7.4.210.0080.00816.77
7.4.200.0040.00416.95
7.4.190.0060.00316.78
7.4.160.0040.01316.78
7.4.150.0070.01117.40
7.4.140.0080.01117.86
7.4.130.0130.00316.80
7.4.120.0110.00816.78
7.4.110.0130.00316.68
7.4.100.0070.01116.69
7.4.90.0160.00716.66
7.4.80.0110.00619.39
7.4.70.0030.01316.52
7.4.60.0060.00916.75
7.4.50.0060.00316.81
7.4.40.0070.01122.52
7.4.30.0110.00816.77
7.4.00.0090.00614.97
7.3.330.0050.00013.33
7.3.320.0050.00013.34
7.3.310.0050.00216.43
7.3.300.0040.00416.54
7.3.290.0070.00716.46
7.3.280.0080.00916.49
7.3.270.0070.01017.40
7.3.260.0080.01018.24
7.3.250.0090.01116.64
7.3.240.0130.00916.53
7.3.230.0160.00316.88
7.3.210.0100.00916.58
7.3.200.0060.01219.39
7.3.190.0150.00316.88
7.3.180.0030.01316.75
7.3.170.0060.00916.73
7.3.160.0040.01216.84
7.3.120.0000.01615.30
7.2.330.0100.01016.95
7.2.320.0120.00816.74
7.2.310.0130.00516.80
7.2.300.0070.01016.78
7.2.290.0070.01416.91
7.2.00.0030.01019.84
7.1.100.0060.00618.12
7.1.70.0000.00717.39
7.1.60.0030.02019.40
7.1.50.0100.01417.06
7.1.00.0030.03322.46
7.0.200.0000.00716.96
7.0.140.0070.07022.07
7.0.70.0000.08321.75
7.0.60.0130.07021.78
7.0.50.0070.08322.09
7.0.40.0070.08019.91
7.0.30.0030.08020.13
7.0.20.0070.05320.17
7.0.10.0070.07020.13
7.0.00.0070.07720.12
5.6.280.0100.06321.09
5.6.220.0130.06720.55
5.6.210.0030.08720.43
5.6.200.0030.08721.12
5.6.190.0000.07320.95
5.6.180.0100.07021.00
5.6.170.0130.07321.07
5.6.160.0030.04720.95
5.6.150.0100.07021.00
5.6.140.0030.08321.13
5.6.130.0000.08721.11
5.6.120.0000.08020.99
5.6.110.0000.09021.02
5.6.100.0070.05320.92
5.6.90.0100.08021.00
5.6.80.0030.07720.39
5.6.70.0000.07720.41
5.6.60.0000.06320.31
5.6.50.0030.04720.37
5.6.40.0030.06020.40
5.6.30.0070.07020.39
5.6.20.0000.08020.30
5.6.10.0000.08720.45
5.6.00.0100.07020.28
5.5.360.0070.07320.29
5.5.350.0030.05320.41
5.5.340.0030.08320.86
5.5.330.0070.08020.90
5.5.320.0070.08020.71
5.5.310.0070.07320.85
5.5.300.0070.08020.89
5.5.290.0030.08720.84
5.5.280.0070.08320.90
5.5.270.0000.09020.86
5.5.260.0030.08320.88
5.5.250.0070.07020.69
5.5.240.0000.08320.20
5.5.230.0000.08320.25
5.5.220.0030.06020.19
5.5.210.0070.05320.23
5.5.200.0070.06719.98
5.5.190.0070.06020.23
5.5.180.0000.08320.09
5.5.160.0030.07020.13
5.5.150.0070.08020.21
5.5.140.0070.05720.22
5.5.130.0030.08020.09
5.5.120.0030.05720.20
5.5.110.0030.05720.11
5.5.100.0070.08020.06
5.5.90.0070.06720.09
5.5.80.0000.08019.96
5.5.70.0070.06720.12
5.5.60.0030.05020.14
5.5.50.0030.08020.03
5.5.40.0000.08020.13
5.5.30.0000.06319.97
5.5.20.0030.04020.06
5.5.10.0100.05019.99
5.5.00.0130.06720.08
5.4.450.0030.07719.39
5.4.440.0000.08719.43
5.4.430.0070.03719.34
5.4.420.0070.08019.45
5.4.410.0100.07318.97
5.4.400.0000.06319.02
5.4.390.0070.04718.80
5.4.380.0030.04019.03
5.4.370.0000.06319.11
5.4.360.0030.08319.09
5.4.350.0030.07319.11
5.4.340.0030.08719.09
5.4.320.0070.07019.21
5.4.310.0030.07319.21
5.4.300.0030.06318.95
5.4.290.0000.07319.02
5.4.280.0100.05019.05
5.4.270.0100.07019.11
5.4.260.0030.06319.11
5.4.250.0000.08019.13
5.4.240.0070.07318.95
5.4.230.0000.07319.02
5.4.220.0000.06718.97
5.4.210.0030.07318.88
5.4.200.0000.07719.07
5.4.190.0000.04319.07
5.4.180.0030.07718.80
5.4.170.0070.08019.09
5.4.160.0070.05319.04
5.4.150.0070.05719.09
5.4.140.0030.05716.27
5.4.130.0000.08016.01
5.4.120.0030.07716.25
5.4.110.0000.07716.42
5.4.100.0100.06016.31
5.4.90.0070.04716.43
5.4.80.0000.05316.19
5.4.70.0030.06316.19
5.4.60.0070.04316.27
5.4.50.0000.03716.34
5.4.40.0000.04016.26
5.4.30.0000.03716.18
5.4.20.0030.03316.30
5.4.10.0000.03716.18
5.4.00.0000.03315.67
5.3.290.0030.07714.66
5.3.280.0030.08014.50
5.3.270.0000.07714.59
5.3.260.0070.04014.46
5.3.250.0030.07314.56
5.3.240.0070.07314.59
5.3.230.0100.06314.50
5.3.220.0070.07014.56
5.3.210.0070.06714.57
5.3.200.0070.06314.54
5.3.190.0070.06314.54
5.3.180.0000.08014.54
5.3.170.0000.06014.50
5.3.160.0030.03714.55
5.3.150.0000.03714.57
5.3.140.0030.03714.49
5.3.130.0030.03714.51
5.3.120.0000.04014.54
5.3.110.0030.03014.54
5.3.100.0000.03714.03
5.3.90.0000.03713.88
5.3.80.0030.03713.99
5.3.70.0000.04014.00
5.3.60.0070.03013.96
5.3.50.0030.03313.94
5.3.40.0000.03013.70
5.3.30.0000.03013.76
5.3.20.0000.03713.64
5.3.10.0000.02713.59
5.3.00.0000.03013.56
5.2.170.0000.02312.54
5.2.160.0030.02312.54
5.2.150.0000.03012.54
5.2.140.0030.02712.54
5.2.130.0000.03012.54
5.2.120.0030.02312.54
5.2.110.0000.02312.54
5.2.100.0000.02312.54
5.2.90.0000.02312.54
5.2.80.0030.02012.54
5.2.70.0000.03012.54
5.2.60.0000.02712.54
5.2.50.0000.02312.54
5.2.40.0030.02012.54
5.2.30.0000.02312.54
5.2.20.0000.02312.54
5.2.10.0030.02012.54
5.2.00.0000.02312.54
5.1.60.0000.02312.54
5.1.50.0000.02012.54
5.1.40.0000.02012.54
5.1.30.0000.02712.54
5.1.20.0000.02312.54
5.1.10.0000.02012.54
5.1.00.0000.02012.54
5.0.50.0000.01712.54
5.0.40.0000.01712.54
5.0.30.0000.02712.54
5.0.20.0000.01712.54
5.0.10.0000.01712.54
5.0.00.0030.02312.54
4.4.90.0000.01312.54
4.4.80.0000.01712.54
4.4.70.0000.01312.54
4.4.60.0000.01312.54
4.4.50.0030.01012.54
4.4.40.0000.02712.54
4.4.30.0000.01312.54
4.4.20.0070.00712.54
4.4.10.0030.01012.54
4.4.00.0000.02012.54
4.3.110.0030.01012.54
4.3.100.0000.01012.54
4.3.90.0030.01012.54
4.3.80.0000.02012.54
4.3.70.0000.01012.54
4.3.60.0000.01012.54
4.3.50.0000.01312.54
4.3.40.0000.02012.54
4.3.30.0000.01312.54
4.3.20.0000.01312.54
4.3.10.0030.01012.54
4.3.00.0000.01312.54

preferences:
54.49 ms | 401 KiB | 5 Q