3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = <<<STR Featuring six amazing National Parks: Glacier, Waterton Lakes, Yellowstone, Grand Teton, Arches, and Canyonlands. Your tour begins in Chicago where you will board the Empire Builder bound for the first National Park on your trip, Glacier, where you will explore the famed Going-to-the-Sun Road and enjoy a full-day excursion to Waterton Lakes National Park in Canada (passport required). STR; echo preg_replace('/(?<!\n) *\n(?=[^\n])/', '', $str);

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.40.0130.00618.77
8.3.30.0100.00718.79
8.3.20.0040.00418.89
8.3.10.0080.00020.92
8.3.00.0000.00821.90
8.2.170.0130.00622.96
8.2.160.0070.01020.35
8.2.150.0040.00724.18
8.2.140.0040.00424.66
8.2.130.0030.00526.16
8.2.120.0040.00421.16
8.2.110.0030.00620.52
8.2.100.0080.00318.03
8.2.90.0040.00419.21
8.2.80.0000.00817.97
8.2.70.0050.00517.63
8.2.60.0000.01018.03
8.2.50.0080.00018.07
8.2.40.0040.00418.16
8.2.30.0070.00319.39
8.2.20.0050.00217.90
8.2.10.0080.00017.83
8.2.00.0040.00417.79
8.1.270.0020.00523.99
8.1.260.0040.00426.35
8.1.250.0000.00728.09
8.1.240.0030.00622.34
8.1.230.0110.00020.91
8.1.220.0040.00418.77
8.1.210.0000.00818.97
8.1.200.0030.00717.35
8.1.190.0070.00017.41
8.1.180.0050.00318.10
8.1.170.0030.00518.64
8.1.160.0070.00318.80
8.1.150.0000.00718.74
8.1.140.0040.00417.59
8.1.130.0000.00717.91
8.1.120.0070.00017.58
8.1.110.0040.00417.57
8.1.100.0070.00017.58
8.1.90.0040.00417.48
8.1.80.0080.00017.46
8.1.70.0000.00717.53
8.1.60.0080.00017.68
8.1.50.0070.00017.59
8.1.40.0040.00417.67
8.1.30.0040.00417.73
8.1.20.0000.00817.78
8.1.10.0000.00717.73
8.1.00.0050.00617.64
8.0.300.0000.00720.03
8.0.290.0000.00817.18
8.0.280.0040.00418.43
8.0.270.0030.00317.29
8.0.260.0090.00017.05
8.0.250.0060.00317.12
8.0.240.0040.00817.11
8.0.230.0060.00317.01
8.0.220.0030.00317.02
8.0.210.0000.00717.05
8.0.200.0080.00016.94
8.0.190.0000.00817.07
8.0.180.0040.00416.98
8.0.170.0060.00317.08
8.0.160.0000.00716.88
8.0.150.0030.00317.01
8.0.140.0000.00716.90
8.0.130.0060.00013.47
8.0.120.0050.00316.88
8.0.110.0040.00416.89
8.0.100.0000.00817.04
8.0.90.0070.00016.88
8.0.80.0090.00616.98
8.0.70.0040.00416.99
8.0.60.0000.00817.00
8.0.50.0000.00817.09
8.0.30.0100.01117.16
8.0.20.0110.00717.40
8.0.10.0070.00017.20
8.0.00.0160.00216.63
7.4.330.0000.00516.85
7.4.320.0000.00616.66
7.4.300.0060.00016.77
7.4.290.0000.00716.75
7.4.280.0050.00316.71
7.4.270.0060.00016.79
7.4.260.0030.00313.55
7.4.250.0040.00416.63
7.4.240.0040.00416.76
7.4.230.0030.00316.57
7.4.220.0090.00616.65
7.4.210.0080.00916.71
7.4.200.0030.00316.70
7.4.190.0040.00416.89
7.4.160.0180.00316.75
7.4.150.0150.00317.40
7.4.140.0080.00817.86
7.4.130.0030.01616.71
7.4.120.0140.00516.63
7.4.110.0100.00716.79
7.4.100.0170.00716.73
7.4.90.0120.01216.69
7.4.80.0100.00719.39
7.4.70.0100.00716.77
7.4.60.0090.00616.53
7.4.50.0000.00816.56
7.4.40.0030.01422.77
7.4.30.0070.01016.68
7.4.00.0080.00815.00
7.3.330.0030.00313.27
7.3.320.0000.00513.14
7.3.310.0070.00016.45
7.3.300.0000.00716.38
7.3.290.0040.01116.29
7.3.280.0080.00916.37
7.3.270.0260.02817.40
7.3.260.0100.00618.24
7.3.250.0070.01116.52
7.3.240.0100.00716.70
7.3.230.0100.00616.61
7.3.210.0090.00916.38
7.3.200.0060.01219.39
7.3.190.0060.01116.48
7.3.180.0030.01416.34
7.3.170.0150.00616.74
7.3.160.0060.01016.64
7.3.120.0000.01414.88
7.3.10.0040.00416.64
7.3.00.0070.00416.78
7.2.330.0100.00716.79
7.2.320.0060.01316.68
7.2.310.0060.01316.59
7.2.300.0090.01216.74
7.2.290.0120.00616.80
7.2.130.0030.00716.71
7.2.120.0060.00617.04
7.2.110.0030.00616.54
7.2.100.0030.00716.66
7.2.90.0040.00416.64
7.2.80.0080.00316.94
7.2.70.0000.00916.72
7.2.60.0050.00516.72
7.2.50.0040.00416.96
7.2.40.0080.00416.57
7.2.30.0030.00617.05
7.2.20.0030.01016.88
7.2.10.0060.00316.78
7.2.00.0100.00517.95
7.1.250.0040.00415.88
7.1.100.0060.00618.25
7.1.70.0030.00717.22
7.1.60.0140.01019.40
7.1.50.0100.01417.00
7.1.00.0030.07022.46
7.0.200.0110.00715.06
7.0.140.0030.07321.95
7.0.80.0030.06020.02
7.0.70.0100.08020.00
7.0.60.0070.05719.93
7.0.50.0170.07720.28
7.0.40.0030.08020.14
7.0.30.0070.08320.05
7.0.20.0100.06720.04
7.0.10.0100.05019.99
7.0.00.0170.08020.10
5.6.280.0030.07321.04
5.6.230.0100.06020.65
5.6.220.0070.07720.58
5.6.210.0070.07020.69
5.6.200.0030.06721.02
5.6.190.0100.08321.04
5.6.180.0100.08321.05
5.6.170.0070.07721.09
5.6.160.0030.05721.06
5.6.150.0100.07721.04
5.6.140.0170.07721.16
5.6.130.0070.08321.07
5.6.120.0100.04721.07
5.6.110.0070.08321.04
5.6.100.0200.07321.09
5.6.90.0030.07721.04
5.6.80.0070.06720.49
5.6.70.0100.08020.45
5.6.60.0100.08320.37
5.6.50.0030.08320.33
5.6.40.0070.03720.31
5.6.30.0070.03720.44
5.6.20.0130.07320.39
5.6.10.0000.05020.38
5.6.00.0030.07720.39
5.5.370.0100.04320.49
5.5.360.0070.06720.52
5.5.350.0100.07720.44
5.5.340.0130.08020.77
5.5.330.0170.08020.89
5.5.320.0070.08720.73
5.5.310.0030.08720.77
5.5.300.0070.04020.90
5.5.290.0030.07320.89
5.5.280.0100.04020.79
5.5.270.0030.07320.72
5.5.260.0030.06020.77
5.5.250.0070.08320.73
5.5.240.0130.06720.14
5.5.230.0170.07020.20
5.5.220.0100.07720.30
5.5.210.0030.05320.25
5.5.200.0030.04320.18
5.5.190.0100.03320.25
5.5.180.0070.05320.11
5.5.160.0070.05020.11
5.5.150.0030.04019.98
5.5.140.0070.03720.23
5.5.130.0030.04020.14
5.5.120.0130.03720.26
5.5.110.0000.04320.20
5.5.100.0000.04320.07
5.5.90.0000.04019.95
5.5.80.0000.04319.97
5.5.70.0070.03720.02
5.5.60.0000.04720.09
5.5.50.0000.04320.15
5.5.40.0000.03720.11
5.5.30.0030.04020.09
5.5.20.0030.03720.10
5.5.10.0100.04320.11
5.5.00.0030.03719.92
5.4.450.0070.05719.23
5.4.440.0130.07319.11
5.4.430.0070.06019.39
5.4.420.0130.06019.30
5.4.410.0070.04719.13
5.4.400.0070.07318.97
5.4.390.0070.07719.06
5.4.380.0170.06719.06
5.4.370.0030.05019.03
5.4.360.0030.08019.10
5.4.350.0030.04019.14
5.4.340.0030.04719.05
5.4.320.0070.04018.79
5.4.310.0030.03718.78
5.4.300.0000.04018.98
5.4.290.0030.04718.90
5.4.280.0030.03719.05
5.4.270.0070.04719.05
5.4.260.0000.04019.11
5.4.250.0030.03719.00
5.4.240.0000.04019.02
5.4.230.0000.06318.75
5.4.220.0030.03319.22
5.4.210.0000.04018.88
5.4.200.0000.04019.09
5.4.190.0030.06719.06
5.4.180.0070.03019.10
5.4.170.0070.03719.02
5.4.160.0000.04318.94
5.4.150.0000.04318.96
5.4.140.0030.03716.37
5.4.130.0000.04016.13
5.4.120.0070.06316.36
5.4.110.0070.04016.26
5.4.100.0030.03716.33
5.4.90.0000.03716.30
5.4.80.0000.03716.24
5.4.70.0000.04016.24
5.4.60.0030.03316.18
5.4.50.0030.07016.27
5.4.40.0100.03316.45
5.4.30.0030.03316.21
5.4.20.0070.03316.31
5.4.10.0070.03316.35
5.4.00.0030.03715.78
5.3.290.0030.03714.52
5.3.280.0070.04014.55
5.3.270.0000.04014.43
5.3.260.0100.03314.46
5.3.250.0070.07314.56
5.3.240.0030.03714.59
5.3.230.0000.04014.42
5.3.220.0070.03314.54
5.3.210.0070.03314.42
5.3.200.0000.04014.55
5.3.190.0070.03314.55
5.3.180.0030.03014.52
5.3.170.0000.04014.44
5.3.160.0000.04314.57
5.3.150.0000.06714.51
5.3.140.0000.04314.55
5.3.130.0130.05014.52
5.3.120.0030.03714.52
5.3.110.0000.04014.55
5.3.100.0000.04013.98
5.3.90.0000.04013.95
5.3.80.0030.04013.96
5.3.70.0030.03714.00
5.3.60.0000.04013.96
5.3.50.0030.03313.93
5.3.40.0100.05713.80
5.3.30.0000.03713.66
5.3.20.0030.03313.69
5.3.10.0000.03713.41
5.3.00.0030.05713.58
5.2.170.0000.04011.70
5.2.160.0000.02711.70
5.2.150.0000.03711.70
5.2.140.0000.03011.70
5.2.130.0070.05311.70
5.2.120.0000.04011.70
5.2.110.0000.03311.70
5.2.100.0000.06311.70
5.2.90.0030.03711.70
5.2.80.0000.04311.70
5.2.70.0070.05711.70
5.2.60.0000.04011.70
5.2.50.0070.06311.70
5.2.40.0000.04711.70
5.2.30.0070.03711.70
5.2.20.0030.05311.70
5.2.10.0030.06011.70
5.2.00.0030.03311.70
5.1.60.0030.06011.70
5.1.50.0070.05011.70
5.1.40.0070.03711.70
5.1.30.0100.05011.70
5.1.20.0070.04711.70
5.1.10.0000.04711.70
5.1.00.0070.04011.70
5.0.50.0100.04311.70
5.0.40.0070.03011.70
5.0.30.0030.05711.70
5.0.20.0000.04711.70
5.0.10.0100.04011.70
5.0.00.0130.06011.70
4.4.90.0030.02011.70
4.4.80.0030.03311.70
4.4.70.0000.02011.70
4.4.60.0000.02711.70
4.4.50.0000.03011.70
4.4.40.0070.03311.70
4.4.30.0030.03711.70
4.4.20.0030.03011.70
4.4.10.0000.03311.70
4.4.00.0030.05711.70
4.3.110.0030.03311.70
4.3.100.0030.03311.70
4.3.90.0030.03011.70
4.3.80.0000.05711.70
4.3.70.0030.02311.70
4.3.60.0130.02311.70
4.3.50.0000.03311.70
4.3.40.0000.04711.70
4.3.30.0000.03011.70
4.3.20.0030.03311.70
4.3.10.0000.03711.70
4.3.00.0070.02711.70

preferences:
43.98 ms | 400 KiB | 5 Q