3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = 'I am flying from "Detroit to Vancouver" this to July'; $stopwords = array( "to", "anotherstopword", "andanother"); echo preg_replace('/"[^"\\\\]*(?>\\\\.[^"\\\\]*)*"(*SKIP)(*F)|\b(' . implode ('|', array_map('preg_quote', $stopwords)) . ')\b\h*/', '', $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.5.10.0090.00816.65
8.5.00.0150.00620.31
8.4.150.0030.00014.05
8.4.140.0080.01317.48
8.4.130.0120.00917.88
8.4.120.0050.00520.56
8.4.110.0150.00618.71
8.4.100.0120.00917.82
8.4.90.0130.00917.98
8.4.80.0100.00717.81
8.4.70.0110.00917.94
8.4.60.0150.00618.83
8.4.50.0100.01018.61
8.4.40.0100.01018.13
8.4.30.0100.01017.67
8.4.20.0090.01219.61
8.4.10.0040.00417.70
8.3.280.0030.00014.05
8.3.270.0110.01016.60
8.3.260.0130.00616.61
8.3.250.0040.00518.92
8.3.240.0160.00416.68
8.3.230.0100.01117.00
8.3.220.0080.01218.36
8.3.210.0080.01216.69
8.3.200.0120.00516.60
8.3.190.0050.00417.22
8.3.180.0120.00616.57
8.3.170.0070.01118.89
8.3.160.0130.01017.19
8.3.150.0040.00417.19
8.3.140.0140.00416.70
8.3.130.0040.00416.91
8.3.120.0160.00319.08
8.3.110.0050.00320.94
8.3.100.0070.00724.06
8.3.90.0090.00026.77
8.3.80.0030.00616.88
8.3.70.0000.01816.88
8.3.60.0110.01118.64
8.3.50.0100.01117.10
8.3.40.0090.00918.98
8.3.30.0070.01418.76
8.3.20.0050.00319.16
8.3.10.0060.00320.78
8.3.00.0000.00819.56
8.2.290.0110.00520.30
8.2.280.0100.00920.40
8.2.270.0150.00417.05
8.2.260.0110.00717.05
8.2.250.0070.00718.78
8.2.240.0200.00016.81
8.2.230.0050.00522.58
8.2.220.0090.00037.54
8.2.210.0080.01226.77
8.2.200.0100.00016.50
8.2.190.0100.01316.58
8.2.180.0030.01025.92
8.2.170.0110.01119.01
8.2.160.0000.01420.90
8.2.150.0000.00824.18
8.2.140.0080.00024.66
8.2.130.0110.00726.16
8.2.120.0030.00521.06
8.2.110.0060.00321.24
8.2.100.0090.00319.25
8.2.90.0000.00817.88
8.2.80.0080.00018.91
8.2.70.0000.00817.75
8.2.60.0030.00517.75
8.2.50.0080.00018.10
8.2.40.0000.00821.15
8.2.30.0050.00219.32
8.2.20.0000.00818.12
8.2.10.0040.00418.15
8.2.00.0000.00819.52
8.1.330.0100.01116.70
8.1.320.0150.00416.35
8.1.310.0110.00416.58
8.1.300.0080.00818.09
8.1.290.0030.00618.88
8.1.280.0040.01225.92
8.1.270.0040.00422.19
8.1.260.0030.00626.35
8.1.250.0040.00428.09
8.1.240.0090.00021.17
8.1.230.0070.00320.96
8.1.220.0030.00518.84
8.1.210.0000.00818.77
8.1.200.0040.00417.48
8.1.190.0030.00617.35
8.1.180.0040.00418.10
8.1.170.0030.00618.52
8.1.160.0020.00520.77
8.1.150.0000.00718.91
8.1.140.0080.00017.66
8.1.130.0080.00019.09
8.1.120.0050.00517.63
8.1.110.0070.00017.59
8.1.100.0000.00817.64
8.1.90.0000.00817.63
8.1.80.0080.00017.50
8.1.70.0000.01017.61
8.1.60.0040.00417.72
8.1.50.0040.00417.71
8.1.40.0050.00217.62
8.1.30.0050.00317.82
8.1.20.0020.00617.76
8.1.10.0010.00717.59
8.1.00.0040.00517.59
8.0.300.0030.00618.77
8.0.290.0030.00516.88
8.0.280.0040.00418.53
8.0.270.0000.00716.96
8.0.260.0000.00718.52
8.0.250.0030.00317.10
8.0.240.0030.00317.02
8.0.230.0070.00017.00
8.0.220.0000.00716.96
8.0.210.0000.00717.02
8.0.200.0040.00417.12
8.0.190.0040.00417.10
8.0.180.0040.00417.08
8.0.170.0090.00017.05
8.0.160.0020.00517.07
8.0.150.0020.00616.98
8.0.140.0020.00616.95
8.0.130.0030.00415.24
8.0.120.0010.00617.00
8.0.110.0040.00417.05
8.0.100.0040.00417.00
8.0.90.0030.00517.01
8.0.80.0040.01017.04
8.0.70.0020.00517.01
8.0.60.0040.00416.91
8.0.50.0020.00517.00
8.0.30.0090.00617.18
8.0.20.0080.00617.27
8.0.10.0030.00417.02
8.0.00.0100.00716.98
7.4.330.0020.00215.55
7.4.320.0000.00616.75
7.4.300.0060.00016.75
7.4.290.0000.00716.70
7.4.280.0030.00616.73
7.4.270.0050.00416.64
7.4.260.0050.00216.66
7.4.250.0020.00616.57
7.4.240.0040.00416.71
7.4.230.0050.00316.73
7.4.220.0050.00216.71
7.4.210.0020.01016.67
7.4.200.0030.00416.66
7.4.190.0000.00816.78
7.4.180.0040.00416.68
7.4.160.0060.00516.66
7.4.150.0110.00016.60
7.4.140.0070.01417.58
7.4.130.0090.00916.60
7.4.120.0090.01016.69
7.4.110.0090.00516.56
7.4.100.0060.00816.63
7.4.90.0110.00616.67
7.4.80.0070.00718.03
7.4.70.0060.00916.59
7.4.60.0070.00816.52
7.4.50.0040.00916.51
7.4.40.0050.01116.57
7.4.30.0080.00316.64
7.4.20.0070.00016.54
7.4.10.0000.00816.45
7.4.00.0020.01215.40
7.3.330.0080.00414.77
7.3.320.0090.00614.81
7.3.310.0090.00516.29
7.3.300.0090.00316.20
7.3.290.0130.00016.34
7.3.280.0080.01016.36
7.3.270.0150.00416.46
7.3.260.0140.00516.50
7.3.250.0160.00316.16
7.3.240.0100.00816.50
7.3.230.0120.00816.53
7.3.220.0100.00816.23
7.3.210.0110.00716.33
7.3.200.0080.01016.51
7.3.190.0130.00816.32
7.3.180.0140.00416.38
7.3.170.0120.00616.31
7.3.160.0130.00516.29
7.3.150.0160.00316.35
7.3.140.0190.00016.33
7.3.130.0120.00616.39
7.3.120.0180.00015.61
7.3.110.0110.00815.49
7.3.100.0070.01015.63
7.3.90.0110.00415.75
7.3.80.0030.01215.68
7.3.70.0100.00615.73
7.3.60.0070.00815.70
7.3.50.0070.00915.81
7.3.40.0090.00815.75
7.3.30.0110.00715.64
7.3.20.0100.00617.52
7.3.10.0110.00617.54
7.3.00.0090.00717.45
7.2.340.0180.00016.38
7.2.330.0140.00716.57
7.2.320.0100.00816.66
7.2.310.0150.00316.53
7.2.300.0100.01016.59
7.2.290.0170.00416.53
7.2.280.0160.00316.32
7.2.270.0150.00416.41
7.2.260.0150.00416.49
7.2.250.0110.01015.91
7.2.240.0070.01215.92
7.2.230.0100.00715.69
7.2.220.0060.00915.79
7.2.210.0020.01215.81
7.2.200.0130.00515.98
7.2.190.0130.00415.96
7.2.180.0120.00715.92
7.2.170.0130.00215.85
7.2.160.0140.00516.47
7.2.150.0160.00318.63
7.2.140.0170.00218.48
7.2.130.0120.00818.54
7.2.120.0190.00018.47
7.2.110.0150.00418.60
7.2.100.0160.00318.37
7.2.90.0170.00318.31
7.2.80.0160.00318.62
7.2.70.0130.00618.64
7.2.60.0640.00716.29
7.2.50.0650.00816.27
7.2.40.0580.00716.50
7.2.30.1070.00916.40
7.2.20.1040.00816.45
7.2.10.0800.01016.29
7.2.00.1000.00916.49
7.1.330.0110.00516.70
7.1.320.0120.00416.76
7.1.310.0120.00416.62
7.1.300.0080.00616.57
7.1.290.0130.00016.57
7.1.280.0060.01016.62
7.1.270.0080.00816.74
7.1.260.0140.00316.60
7.1.250.0140.00317.35
7.1.240.0110.00617.11
7.1.230.0150.00317.50
7.1.220.0140.00417.22
7.1.210.0120.00617.41
7.1.200.0120.00316.51
7.1.190.0160.00517.16
7.1.180.0070.01117.25
7.1.170.0680.00715.17
7.1.160.0690.00817.07
7.1.150.0690.00816.99
7.1.140.1250.00917.24
7.1.130.1130.01017.10
7.1.120.0960.01016.94
7.1.110.0900.00916.72
7.1.100.0980.00716.72
7.1.90.0860.00616.78
7.1.80.0910.01116.80
7.1.70.1040.00716.03
7.1.60.1190.01528.01
7.1.50.1200.01027.95
7.1.40.1460.01127.68
7.1.30.1260.00927.67
7.1.20.1190.01027.78
7.1.10.1040.00715.82
7.1.00.0940.00815.73
7.0.330.0180.00017.01
7.0.320.0130.00517.17
7.0.310.0100.00716.93
7.0.300.0120.00516.93
7.0.290.0140.00416.95
7.0.280.0160.00017.13
7.0.270.0140.00616.94
7.0.260.0120.00417.16
7.0.250.0180.00017.25
7.0.240.0120.00617.34
7.0.230.0140.00317.23
7.0.220.0130.00316.97
7.0.210.0120.00617.21
7.0.200.0110.00616.98
7.0.190.0110.00617.20
7.0.180.0110.00617.01
7.0.170.0150.00417.15
7.0.160.0170.00017.21
7.0.150.0180.00017.05
7.0.140.0180.00016.90
7.0.130.0170.00017.02
7.0.120.0130.00517.16
7.0.110.0190.00016.84
7.0.100.0140.00317.19
7.0.90.0130.00416.96
7.0.80.0070.01016.95
7.0.70.0100.00716.95
7.0.60.0130.00516.80
7.0.50.0190.00316.81
7.0.40.0140.00416.82
7.0.30.0120.00516.96
7.0.20.0080.00816.78
7.0.10.0140.00517.02
7.0.00.0150.00416.98
5.6.400.0100.00715.92
5.6.390.0180.00015.85
5.6.380.0170.00015.86
5.6.370.0140.00415.64
5.6.360.0100.00815.89
5.6.350.0130.00415.66
5.6.340.0130.00415.66
5.6.330.0170.00015.89
5.6.320.0090.00915.68
5.6.310.0080.00815.79
5.6.300.0090.00915.79
5.6.290.0120.00415.88
5.6.280.0140.00315.77
5.6.270.0170.00015.84
5.6.260.0120.00715.85
5.6.250.0120.00815.80
5.6.240.0150.00315.77
5.6.230.0100.00716.03
5.6.220.0140.00315.96
5.6.210.0110.00615.88
5.6.200.0110.00516.04
5.6.190.0140.00316.02
5.6.180.0080.00815.79
5.6.170.0040.01216.02
5.6.160.0120.00415.95
5.6.150.0110.00516.04
5.6.140.0130.00315.95
5.6.130.0170.00015.84
5.6.120.0100.00715.84
5.6.110.0120.00515.71
5.6.100.0070.01015.83
5.6.90.0090.00915.86
5.6.80.0100.00615.79
5.6.70.0100.00715.93
5.6.60.0100.00515.79
5.6.50.0120.00415.83
5.6.40.0160.00015.89
5.6.30.0110.00615.89
5.6.20.0130.00315.63
5.6.10.0120.00415.81
5.6.00.0130.00315.78

preferences:
38.29 ms | 403 KiB | 5 Q