3v4l.org

run code in 300+ PHP versions simultaneously
<?php $strings = [ "First example from this part 10 t/m 16 it has to be removed", "Second example from this part 12 t/m 22 it has to be removed" ]; foreach ($strings as $string) { $parts = explode(" ", $string); echo implode(" ", [$parts[0], $parts[1]]) . PHP_EOL; }

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.4.130.0120.00917.71
8.4.120.0150.00520.52
8.4.110.0120.00822.35
8.4.100.0130.00717.71
8.4.90.0110.00718.50
8.4.80.0040.00517.91
8.4.70.0110.01018.00
8.4.60.0140.00618.65
8.4.50.0120.00717.80
8.4.40.0170.00319.28
8.4.30.0040.01217.63
8.4.20.0100.01019.55
8.4.10.0100.00718.77
8.3.260.0050.00316.64
8.3.250.0070.01119.16
8.3.240.0110.00716.36
8.3.230.0110.00816.49
8.3.220.0110.00617.39
8.3.210.0100.00916.54
8.3.200.0080.01116.41
8.3.190.0100.00917.29
8.3.180.0130.00516.61
8.3.170.0060.01317.35
8.3.160.0050.00316.58
8.3.150.0030.01618.93
8.3.140.0060.00317.03
8.3.130.0120.00318.37
8.3.120.0070.01018.87
8.3.110.0000.00920.94
8.3.100.0090.00024.06
8.3.90.0050.00326.77
8.3.80.0060.00318.43
8.3.70.0090.00918.55
8.3.60.0070.00718.25
8.3.50.0120.00818.31
8.3.40.0100.00618.81
8.3.30.0000.01418.71
8.3.20.0070.00721.60
8.3.10.0030.00623.54
8.3.00.0040.00419.79
8.2.290.0110.00820.50
8.2.280.0060.00418.38
8.2.270.0110.00717.11
8.2.260.0120.00616.63
8.2.250.0030.00716.57
8.2.240.0040.00417.24
8.2.230.0030.00622.58
8.2.220.0040.00437.54
8.2.210.0050.00326.77
8.2.200.0060.00316.50
8.2.190.0090.00616.63
8.2.180.0040.01418.41
8.2.170.0060.00922.96
8.2.160.0130.00622.08
8.2.150.0050.00324.18
8.2.140.0040.00424.66
8.2.130.0040.00418.03
8.2.120.0050.00226.35
8.2.110.0060.00322.18
8.2.100.0090.00317.91
8.2.90.0000.00718.28
8.2.80.0090.00020.39
8.2.70.0040.00417.93
8.2.60.0030.00618.05
8.2.50.0000.00918.34
8.2.40.0000.00720.59
8.2.30.0000.00719.38
8.2.20.0030.00518.00
8.2.10.0050.00318.03
8.2.00.0030.00318.17
8.1.330.0090.01021.77
8.1.320.0130.00716.02
8.1.310.0040.00416.81
8.1.300.0040.00418.38
8.1.290.0060.00330.84
8.1.280.0070.00725.92
8.1.270.0040.00423.82
8.1.260.0070.00026.35
8.1.250.0000.00828.09
8.1.240.0080.00023.82
8.1.230.0110.00020.91
8.1.220.0050.00317.79
8.1.210.0050.00318.77
8.1.200.0030.00517.23
8.1.190.0090.00017.22
8.1.180.0030.00518.10
8.1.170.0080.00018.64
8.1.160.0040.00418.94
8.1.150.0030.00319.01
8.1.140.0040.00417.64
8.1.130.0030.00319.07
8.1.120.0000.00717.51
8.1.110.0040.00317.48
8.1.100.0000.00717.36
8.1.90.0000.00817.52
8.1.80.0000.00717.46
8.1.70.0040.00417.45
8.1.60.0030.00517.46
8.1.50.0000.00817.42
8.1.40.0000.00717.57
8.1.30.0040.00417.66
8.1.20.0030.00517.53
8.1.10.0090.00017.55
8.1.00.0000.00817.55
8.0.300.0040.00420.07
8.0.290.0070.00016.75
8.0.280.0000.00818.49
8.0.270.0000.00717.26
8.0.260.0030.00317.22
8.0.250.0060.00016.85
8.0.240.0060.00316.84
8.0.230.0000.00717.01
8.0.220.0040.00416.90
8.0.210.0040.00416.85
8.0.200.0070.00017.02
8.0.190.0040.00416.95
8.0.180.0040.00416.97
8.0.170.0030.00616.97
8.0.160.0080.00316.95
8.0.150.0030.00516.84
8.0.140.0030.00316.84
8.0.130.0070.00013.27
8.0.120.0040.00416.82
8.0.110.0070.00016.94
8.0.100.0000.00816.80
8.0.90.0000.00716.96
8.0.80.0060.00916.94
8.0.70.0070.00016.75
8.0.60.0040.00416.78
8.0.50.0000.00716.83
8.0.30.0110.00917.02
8.0.20.0160.00517.40
8.0.10.0040.00416.90
8.0.00.0110.00816.68
7.4.330.0000.00515.55
7.4.320.0030.00316.49
7.4.300.0060.00016.51
7.4.290.0030.00316.50
7.4.280.0050.00316.39
7.4.270.0070.00016.42
7.4.260.0020.00516.52
7.4.250.0070.00016.46
7.4.240.0050.00316.49
7.4.230.0070.00016.68
7.4.220.0030.00516.48
7.4.210.0040.01416.61
7.4.200.0000.00716.35
7.4.160.0070.00916.41
7.4.140.0110.00717.86
7.4.130.0060.01216.38
7.4.120.0090.01216.58
7.4.110.0110.00616.38
7.4.100.0120.00916.68
7.4.90.0070.01016.51
7.4.80.0140.00819.39
7.4.70.0030.01316.55
7.4.60.0030.01216.51
7.4.50.0110.00716.54
7.4.40.0090.01216.49
7.4.00.0030.01015.11
7.3.330.0050.00013.13
7.3.320.0050.00013.06
7.3.310.0070.00016.20
7.3.300.0030.00316.29
7.3.290.0030.00316.26
7.3.280.0070.00716.22
7.3.260.0080.00916.55
7.3.240.0070.00916.46
7.3.230.0090.01216.55
7.3.210.0130.00716.68
7.3.200.0060.00916.36
7.3.190.0060.01016.44
7.3.180.0060.01016.33
7.3.170.0080.00816.50
7.3.160.0120.00616.48
7.2.330.0130.01016.54
7.2.320.0100.01016.78
7.2.310.0150.00916.60
7.2.300.0060.00916.46
7.2.290.0130.01016.80
7.2.60.0090.00316.84
7.2.50.0080.00616.96
7.2.40.3360.01618.04
7.2.30.3110.01817.96
7.2.20.3430.01518.14
7.2.10.2660.01018.04
7.2.00.3140.01517.80
7.1.200.0030.00615.86
7.1.160.3820.01716.55
7.1.150.3830.03916.83
7.1.140.3220.01216.77
7.1.130.2850.01416.93
7.1.120.2600.01516.89
7.1.110.3170.00916.28
7.1.100.2950.00716.19
7.1.90.4480.01116.08
7.1.80.3610.01316.24
7.1.70.3870.01215.29
7.1.60.3410.01733.15
7.1.50.1490.01932.85
7.1.40.1410.01832.65
7.1.30.1400.02432.75
7.1.20.1060.01832.80
7.1.10.1070.00614.72
7.1.00.0920.01214.82

preferences:
27.13 ms | 403 KiB | 5 Q