3v4l.org

run code in 300+ PHP versions simultaneously
<? $title = "ดูซีรี่ย์ฝรั่ง Arrow Season 3 Ep.1-1"; $title = strtolower($title); $pattern = array("~\s*(season)\s*(\d+[-]?[0-9]*).*\s*(?:ep[.]?|episode)\s*(\d+[-]?[0-9]*)(\s*)~", "~\s*(?:ep[.]?|episode)\s*(\d+[-]?[0-9]*)(\s*)~"); $title = preg_replace($pattern, array(" $1 $2 ep. $3"," ep. $1"), $title, -1); $title = ucwords($title); $episodename = str_replace("’","'",$title); $pttr = '/[ก-๙]/ui'; $new_str = preg_replace($pttr, '', $episodename); $new_str = preg_replace('/\s+/', ' ', $new_str); $new_str = str_replace('..', '', $new_str); $new_str = trim($new_str); $episode = $new_str; echo $episode; ?>

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.0130.00718.30
8.3.50.0110.00522.07
8.3.40.0140.00018.70
8.3.30.0070.01418.92
8.3.20.0070.00020.34
8.3.10.0040.00423.65
8.3.00.0080.00019.38
8.2.180.0110.00417.92
8.2.170.0070.00722.96
8.2.160.0090.00920.45
8.2.150.0070.00024.18
8.2.140.0040.00424.66
8.2.130.0080.00026.16
8.2.120.0040.00422.23
8.2.110.0060.00320.30
8.2.100.0070.00417.97
8.2.90.0050.00319.03
8.2.80.0040.00417.97
8.2.70.0040.00417.50
8.2.60.0060.00617.79
8.2.50.0090.00018.07
8.2.40.0050.00319.71
8.2.30.0060.00317.96
8.2.20.0040.00417.55
8.2.10.0000.00817.95
8.2.00.0000.00817.61
8.1.280.0110.01125.92
8.1.270.0040.00423.88
8.1.260.0070.00026.35
8.1.250.0080.00028.09
8.1.240.0030.00623.83
8.1.230.0040.00819.15
8.1.220.0000.00817.74
8.1.210.0040.00418.77
8.1.200.0100.00017.23
8.1.190.0000.00817.10
8.1.180.0050.00318.10
8.1.170.0040.00418.51
8.1.160.0000.00721.93
8.1.150.0100.00018.71
8.1.140.0040.00417.24
8.1.130.0030.00317.75
8.1.120.0000.00717.38
8.1.110.0030.00517.38
8.1.100.0040.00417.32
8.1.90.0040.00417.25
8.1.80.0000.00717.39
8.1.70.0050.00317.30
8.1.60.0030.00817.27
8.1.50.0060.00317.34
8.1.40.0060.00317.23
8.1.30.0030.00517.57
8.1.20.0080.00017.54
8.1.10.0000.00817.42
8.1.00.0000.00817.36
8.0.300.0080.00018.77
8.0.290.0000.00716.63
8.0.280.0040.00418.38
8.0.270.0000.00717.05
8.0.260.0060.00017.09
8.0.250.0030.00316.82
8.0.240.0000.00716.90
8.0.230.0000.00716.84
8.0.220.0070.00016.72
8.0.210.0030.00316.67
8.0.200.0040.00416.83
8.0.190.0050.00316.73
8.0.180.0000.00716.80
8.0.170.0000.00916.74
8.0.160.0000.00716.72
8.0.150.0000.00716.67
8.0.140.0000.00816.64
8.0.130.0020.00513.59
8.0.120.0000.00816.68
8.0.110.0040.00416.80
8.0.100.0000.00716.65
8.0.90.0040.00416.79
8.0.80.0130.00316.75
8.0.70.0000.00716.74
8.0.60.0070.00016.67
8.0.50.0000.00816.75
8.0.30.0110.01116.73
8.0.20.0090.01117.40
8.0.10.0000.00716.93
8.0.00.0070.01116.66
7.4.330.0000.00615.13
7.4.320.0030.00316.38
7.4.300.0000.00716.41
7.4.290.0050.00216.42
7.4.280.0050.00316.30
7.4.270.0000.00716.49
7.4.260.0000.00716.25
7.4.250.0050.00316.26
7.4.240.0020.00516.48
7.4.230.0030.00316.54
7.4.220.0030.01516.45
7.4.210.0130.00616.32
7.4.200.0070.00016.30
7.4.160.0070.01016.56
7.4.150.0100.00717.40
7.4.140.0140.01117.86
7.4.130.0110.00916.46
7.4.120.0100.00716.38
7.4.110.0060.01116.28
7.4.100.0090.00916.32
7.4.90.0120.00916.36
7.4.80.0120.00919.39
7.4.70.0130.00716.46
7.4.60.0070.00816.32
7.4.50.0030.00616.42
7.4.40.0070.01016.29
7.4.30.0090.00916.39
7.4.00.0040.01114.60
7.3.330.0030.00313.23
7.3.320.0050.00013.39
7.3.310.0000.00715.93
7.3.300.0000.00716.18
7.3.290.0030.01016.15
7.3.280.0100.00616.11
7.3.270.0160.00717.40
7.3.260.0170.00016.25
7.3.250.0160.01416.32
7.3.240.0060.01016.11
7.3.230.0150.00416.50
7.3.210.0070.01016.32
7.3.200.0140.00919.39
7.3.190.0100.00616.48
7.3.180.0040.01116.13
7.3.170.0100.00716.27
7.3.160.0030.01316.46
7.3.10.0170.00416.20
7.3.00.0100.01016.35
7.2.330.0070.01016.48
7.2.320.0140.00316.51
7.2.310.0100.00716.49
7.2.300.0060.01116.57
7.2.290.0110.01116.32
7.2.130.0100.00716.55
7.2.120.0160.00616.63
7.2.110.0230.00416.31
7.2.100.0090.01216.88
7.2.90.0290.00616.56
7.2.80.0110.00716.76
7.2.70.0160.01316.81
7.2.60.0140.01816.86
7.2.50.0150.00716.94
7.2.40.0130.01516.94
7.2.30.0280.01016.84
7.2.20.0130.01016.74
7.2.10.0300.01016.80
7.2.00.0150.00817.13
7.1.250.0150.00415.98
7.1.200.0060.00615.76
7.1.70.0050.00317.29
7.1.60.0070.01319.32
7.1.50.0100.00317.16
7.1.00.0000.08022.56
7.0.200.0000.01016.96
7.0.140.0000.07722.00
7.0.110.0100.08319.95
7.0.100.0070.08319.95
7.0.90.0170.07020.03
7.0.80.0100.06720.03
7.0.70.0030.08319.83
7.0.60.0100.08319.98
7.0.50.0070.07719.94
7.0.40.0070.07719.61
7.0.30.0030.06019.68
7.0.20.0130.07719.73
7.0.10.0100.08319.79
7.0.00.0100.07719.81
5.6.280.0030.07321.13
5.6.260.0030.07020.45
5.6.250.0100.08020.58
5.6.240.0130.08020.51
5.6.230.0030.07720.42
5.6.220.0030.07020.60
5.6.210.0100.07720.34
5.6.200.0130.08020.53
5.6.190.0170.07720.77
5.6.180.0030.08020.64
5.6.170.0070.04020.41
5.6.160.0130.04020.57
5.6.150.0070.07720.54
5.6.140.0030.09020.50
5.6.130.0130.07720.59
5.6.120.0100.07320.54
5.6.110.0070.06320.50
5.6.100.0070.05020.48
5.6.90.0070.07720.59
5.6.80.0030.08319.97
5.6.70.0030.07719.91
5.6.60.0070.08319.91
5.6.50.0070.04320.03
5.6.40.0130.04720.00
5.6.30.0100.04319.86
5.6.20.0000.04319.81
5.6.10.0000.04019.92
5.6.00.0030.03719.89
5.5.380.0170.07017.50
5.5.370.0100.07717.45
5.5.360.0070.08317.53
5.5.350.0130.08017.48
5.5.340.0100.07718.10
5.5.330.0070.08018.02
5.5.320.0030.08717.89
5.5.310.0070.04717.94
5.5.300.0130.06018.12
5.5.290.0130.07718.09
5.5.280.0070.08018.25
5.5.270.0100.04318.08
5.5.260.0070.08018.24
5.5.250.0130.07717.67
5.5.240.0130.07017.25
5.5.230.0030.06017.23
5.5.220.0070.08317.47
5.5.210.0100.04317.47
5.5.200.0070.04017.23
5.5.190.0130.05717.12
5.5.180.0000.04017.20
5.5.160.0100.03717.24
5.5.150.0030.03717.48
5.5.140.0000.05017.44
5.5.130.0030.07717.44
5.5.120.0030.03717.44
5.5.110.0070.03717.47
5.5.100.0030.03717.10
5.5.90.0100.07017.38
5.5.80.0070.03717.38
5.5.70.0100.07717.46
5.5.60.0070.07017.33
5.5.50.0130.05017.11
5.5.40.0100.07017.36
5.5.30.0030.04717.00
5.5.20.0100.06017.22
5.5.10.0000.08717.49
5.5.00.0030.07317.39
5.4.450.0170.06719.27
5.4.440.0070.07319.37
5.4.430.0130.07019.20
5.4.420.0100.07319.37
5.4.410.0130.05719.26
5.4.400.0100.04719.20
5.4.390.0070.07318.88
5.4.380.0130.07318.98
5.4.370.0000.08318.88
5.4.360.0030.04018.96
5.4.350.0000.06718.93
5.4.340.0070.03718.95
5.4.320.0070.03319.03
5.4.310.0030.04318.95
5.4.300.0070.03319.23
5.4.290.0030.03719.11
5.4.280.0030.04018.88
5.4.270.0030.06018.99
5.4.260.0030.04019.20
5.4.250.0100.03019.21
5.4.240.0030.03718.94
5.4.230.0000.06719.06
5.4.220.0030.07019.23
5.4.210.0100.07718.97
5.4.200.0000.08319.06
5.4.190.0070.07318.97
5.4.180.0000.05318.87
5.4.170.0100.06318.86
5.4.160.0030.05718.90
5.4.150.0100.05018.88
5.4.140.0000.04016.47
5.4.130.0070.04016.26
5.4.120.0070.04016.19
5.4.110.0070.03316.55
5.4.100.0070.03316.42
5.4.90.0070.04716.53
5.4.80.0130.02316.48
5.4.70.0030.03316.14
5.4.60.0100.05316.33
5.4.50.0030.03716.05
5.4.40.0100.06016.48
5.4.30.0000.06716.34
5.4.20.0130.02316.28
5.4.10.0030.03716.20
5.4.00.0100.03015.65
5.3.290.0030.04014.68
5.3.280.0130.07314.45
5.3.270.0030.07014.55
5.3.260.0100.03014.70
5.3.250.0170.02314.50
5.3.240.0100.03014.49
5.3.230.0030.05014.66
5.3.220.0070.03314.41
5.3.210.0000.04014.44
5.3.200.0070.03314.57
5.3.190.0000.04014.55
5.3.180.0100.04014.48
5.3.170.0030.03714.38
5.3.160.0070.03014.50
5.3.150.0000.04014.63
5.3.140.0070.05014.34
5.3.130.0070.05714.47
5.3.120.0030.05014.40
5.3.110.0000.04014.43
5.3.100.0000.04013.87
5.3.90.0030.03714.02
5.3.80.0030.03714.02
5.3.70.0000.04014.11
5.3.60.0030.04313.84
5.3.50.0070.04313.72
5.3.40.0030.03713.95
5.3.30.0030.03313.75
5.3.20.0070.04313.63
5.3.10.0070.05013.67
5.3.00.0070.07013.55
5.2.170.0070.03011.20
5.2.160.0000.03711.09
5.2.150.0030.05011.15
5.2.140.0030.04011.04
5.2.130.0000.03311.03
5.2.120.0030.03011.15
5.2.110.0030.03010.88
5.2.100.0100.06011.12
5.2.90.0000.06311.26
5.2.80.0030.06311.25
5.2.70.0100.05711.07
5.2.60.0030.06710.93
5.2.50.0100.05710.93
5.2.40.0070.06310.89
5.2.30.0100.03710.87
5.2.20.0070.05310.90
5.2.10.0070.05710.85
5.2.00.0030.05710.83
5.1.60.0030.04710.17
5.1.50.0000.05310.05
5.1.40.0030.05310.00
5.1.30.0070.04010.25
5.1.20.0030.06010.48
5.1.10.0000.05010.23
5.1.00.0070.05710.03
5.0.50.0070.0378.52
5.0.40.0000.0378.22
5.0.30.0100.0438.27
5.0.20.0030.0478.17
5.0.10.0030.0408.15
5.0.00.0030.0638.13
4.4.90.0030.0337.08
4.4.80.0070.0307.08
4.4.70.0030.0337.08
4.4.60.0000.0377.08
4.4.50.0000.0377.08
4.4.40.0030.0537.08
4.4.30.0030.0337.08
4.4.20.0000.0377.08
4.4.10.0030.0307.08
4.4.00.0030.0477.08
4.3.110.0000.0377.08
4.3.100.0070.0307.08
4.3.90.0000.0377.08
4.3.80.0030.0407.08
4.3.70.0000.0337.08
4.3.60.0030.0307.08
4.3.50.0030.0337.08
4.3.40.0000.0577.08
4.3.30.0000.0337.08
4.3.20.0000.0377.08
4.3.10.0000.0377.08
4.3.00.0000.0377.08

preferences:
80.44 ms | 401 KiB | 5 Q