3v4l.org

run code in 300+ PHP versions simultaneously
<?php // Fuente: https://gist.github.com/gcoop/701814 function cleanse($string) { if (get_magic_quotes_gpc()) { $string = stripslashes($stringIn); } $search = array('&acirc;€“','&acirc;€œ','&acirc;€˜','&acirc;€™','&Acirc;&pound;','&Acirc;&not;','&acirc;„&cent;'); $replace = array('-','&ldquo;','&lsquo;','&rsquo;','&pound;','&not;','&#8482;'); $string = str_replace($search, $replace, $string); $string = str_replace('&acirc;€', '&rdquo;', $string); $search = array("&#39;", "\xc3\xa2\xc2\x80\xc2\x99", "\xc3\xa2\xc2\x80\xc2\x93", "\xc3\xa2\xc2\x80\xc2\x9d", "\xc3\xa2\x3f\x3f"); $resplace = array("'", "'", ' - ', '"', "'"); $string = str_replace($search, $replace, $string); $quotes = array( "\xC2\xAB" => '"', "\xC2\xBB" => '"', "\xE2\x80\x98" => "'", "\xE2\x80\x99" => "'", "\xE2\x80\x9A" => "'", "\xE2\x80\x9B" => "'", "\xE2\x80\x9C" => '"', "\xE2\x80\x9D" => '"', "\xE2\x80\x9E" => '"', "\xE2\x80\x9F" => '"', "\xE2\x80\xB9" => "'", "\xE2\x80\xBA" => "'", "\xe2\x80\x93" => "-", "\xc2\xb0" => "°", "\xc2\xba" => "°", "\xc3\xb1" => "&#241;", "\x96" => "&#241;", "\xe2\x81\x83" => '&bull;', "\xd5" => "\"" ); return strtr($string, $quotes); } echo "\xE2\x80\x9C";

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.70.0120.00416.58
8.3.60.0040.01116.38
8.3.50.0150.00221.97
8.3.40.0150.00018.71
8.3.30.0040.01118.95
8.3.20.0070.00020.16
8.3.10.0040.00423.53
8.3.00.0050.00318.89
8.2.180.0070.00718.16
8.2.170.0070.00722.96
8.2.160.0100.00320.22
8.2.150.0070.00024.18
8.2.140.0040.00424.66
8.2.130.0000.00726.16
8.2.120.0080.00020.76
8.2.110.0030.00622.26
8.2.100.0060.00619.45
8.2.90.0030.00619.22
8.2.80.0050.00317.97
8.2.70.0030.00617.50
8.2.60.0070.00417.80
8.2.50.0060.00318.07
8.2.40.0030.00521.18
8.2.30.0000.00818.04
8.2.20.0040.00417.55
8.2.10.0030.00518.00
8.2.00.0000.00717.63
8.1.280.0070.01025.92
8.1.270.0080.00023.84
8.1.260.0000.00826.35
8.1.250.0000.00728.09
8.1.240.0050.00322.05
8.1.230.0030.00719.00
8.1.220.0000.00817.74
8.1.210.0000.00818.77
8.1.200.0040.00417.23
8.1.190.0000.00817.13
8.1.180.0060.00318.10
8.1.170.0060.00318.51
8.1.160.0000.00721.95
8.1.150.0040.00418.39
8.1.140.0000.00817.33
8.1.130.0000.00717.77
8.1.120.0040.00417.29
8.1.110.0000.00817.26
8.1.100.0040.00417.30
8.1.90.0000.00717.30
8.1.80.0040.00417.39
8.1.70.0000.00717.28
8.1.60.0090.00017.41
8.1.50.0000.00817.30
8.1.40.0030.00617.46
8.1.30.0080.00017.59
8.1.20.0040.00417.57
8.1.10.0040.00417.52
8.1.00.0080.00017.36
8.0.300.0040.00418.77
8.0.290.0000.00717.04
8.0.280.0040.00318.39
8.0.270.0030.00317.18
8.0.260.0060.00017.25
8.0.250.0060.00016.86
8.0.240.0030.00316.89
8.0.230.0070.00016.74
8.0.220.0000.00716.80
8.0.210.0000.00716.74
8.0.200.0000.00616.74
8.0.190.0030.00316.79
8.0.180.0030.00316.82
8.0.170.0040.00416.80
8.0.160.0040.00416.76
8.0.150.0030.00316.68
8.0.140.0050.00316.56
8.0.130.0000.00613.26
8.0.120.0040.00416.62
8.0.110.0040.00416.75
8.0.100.0040.00416.61
8.0.90.0040.00416.79
8.0.80.0100.01316.67
8.0.70.0070.00016.77
8.0.60.0040.00416.76
8.0.50.0000.00716.68
8.0.30.0080.01016.93
8.0.20.0100.00817.40
8.0.10.0070.00016.94
8.0.00.0090.00816.86
7.4.330.0020.00215.00
7.4.320.0000.00616.38
7.4.300.0070.00016.39
7.4.290.0000.00716.40
7.4.280.0000.00716.38
7.4.270.0030.00316.25
7.4.260.0000.00816.38
7.4.250.0040.00416.44
7.4.240.0000.00716.31
7.4.230.0030.00316.28
7.4.220.0220.00616.52
7.4.210.0100.00716.45
7.4.200.0050.00216.47
7.4.190.0030.00316.38
7.4.160.0070.01316.55
7.4.150.0170.00417.40
7.4.140.0090.00817.86
7.4.130.0110.00616.60
7.4.120.0080.00916.41
7.4.110.0030.01416.45
7.4.100.0100.01316.21
7.4.90.0160.00716.36
7.4.80.0130.00719.39
7.4.70.0090.00916.43
7.4.60.0060.01316.36
7.4.50.0030.00616.27
7.4.40.0110.00716.43
7.4.30.0030.01616.41
7.4.00.0060.00914.80
7.3.330.0000.00513.14
7.3.320.0000.00513.16
7.3.310.0000.00716.14
7.3.300.0000.00715.98
7.3.290.0030.01016.20
7.3.280.0080.01116.16
7.3.270.0100.00717.40
7.3.260.0130.00916.13
7.3.250.0090.01016.35
7.3.240.0140.00816.41
7.3.230.0070.01016.39
7.3.210.0130.00916.44
7.3.200.0090.00619.39
7.3.190.0070.01416.22
7.3.180.0170.00316.56
7.3.170.0100.00616.31
7.3.160.0120.00316.40
7.3.120.0120.00314.61
7.3.10.0080.00616.71
7.3.00.0070.00716.54
7.2.330.0070.01016.59
7.2.320.0150.00616.49
7.2.310.0030.01316.37
7.2.300.0060.01016.41
7.2.290.0140.00316.38
7.2.130.0030.01016.64
7.2.120.0110.00416.71
7.2.110.0070.00716.78
7.2.100.0040.01116.52
7.2.90.0070.00316.80
7.2.80.0080.00816.84
7.2.70.0040.00716.53
7.2.60.0080.00616.89
7.2.50.0070.00316.80
7.2.40.0110.00416.51
7.2.30.0000.01816.52
7.2.20.0110.00716.89
7.2.10.0030.00616.44
7.2.00.0100.00618.05
7.1.250.0040.00415.37
7.1.200.0030.01015.61
7.1.100.0300.00917.31
7.1.70.0000.01316.96
7.1.60.0070.00716.85
7.1.50.0060.00616.55
7.1.00.0100.07022.31
7.0.200.0100.00716.47
7.0.140.0070.07021.92
7.0.70.0030.08321.67
7.0.60.0000.05321.82
7.0.50.0000.04722.05
7.0.40.0030.04320.13
7.0.30.0030.04720.14
7.0.20.0100.07320.00
7.0.10.0100.07020.12
7.0.00.0000.06719.95
5.6.280.0070.06720.84
5.6.220.0030.05020.63
5.6.210.0030.05020.63
5.6.200.0030.05021.06
5.6.190.0000.05721.14
5.6.180.0030.03721.07
5.6.170.0030.08021.04
5.6.160.0070.07721.07
5.6.150.0000.05321.06
5.6.140.0030.05021.07
5.6.130.0030.07321.06
5.6.120.0130.06021.12
5.6.110.0030.05720.96
5.6.100.0030.06321.07
5.6.90.0000.04321.01
5.6.80.0070.07320.34
5.6.70.0000.08320.53
5.6.60.0030.04320.43
5.6.50.0030.08020.58
5.6.40.0100.06720.49
5.6.30.0100.07020.41
5.6.20.0030.08720.45
5.6.10.0000.08320.39
5.6.00.0070.07320.39
5.5.360.0030.04320.37
5.5.350.0130.06720.36
5.5.340.0030.04320.95
5.5.330.0030.05320.79
5.5.320.0030.03320.88
5.5.310.0000.04020.77
5.5.300.0030.04020.93
5.5.290.0000.05020.84
5.5.280.0100.05720.79
5.5.270.0030.08020.93
5.5.260.0030.06020.84
5.5.250.0070.03320.47
5.5.240.0000.04720.31
5.5.230.0030.07320.31
5.5.220.0000.08020.32
5.5.210.0070.07720.12
5.5.200.0100.06720.01
5.5.190.0000.08720.24
5.5.180.0000.08720.25
5.5.160.0100.07320.17
5.5.150.0030.07020.25
5.5.140.0100.06720.26
5.5.130.0070.07320.26
5.5.120.0070.06320.14
5.5.110.0030.04020.15
5.5.100.0030.05020.10
5.5.90.0070.07320.04
5.5.80.0100.07020.11
5.5.70.0100.06720.07
5.5.60.0000.08020.13
5.5.50.0070.07320.18
5.5.40.0070.06720.08
5.5.30.0000.06320.16
5.5.20.0030.08020.13
5.5.10.0100.07719.98
5.5.00.0100.07020.02
5.4.450.0000.05319.49
5.4.440.0100.07319.37
5.4.430.0030.04719.48
5.4.420.0070.06019.21
5.4.410.0030.06019.33
5.4.400.0000.04319.05
5.4.390.0070.07319.23
5.4.380.0070.07019.20
5.4.370.0030.07319.23
5.4.360.0170.06719.11
5.4.350.0000.07719.04
5.4.340.0030.08019.11
5.4.320.0030.08019.20
5.4.310.0070.06319.22
5.4.300.0070.07319.22
5.4.290.0030.05718.87
5.4.280.0170.06718.89
5.4.270.0070.07019.23
5.4.260.0000.04019.20
5.4.250.0100.07319.11
5.4.240.0070.06718.86
5.4.230.0030.07319.20
5.4.220.0030.07319.03
5.4.210.0130.06319.14
5.4.200.0030.07719.13
5.4.190.0070.06319.11
5.4.180.0030.08019.01
5.4.170.0100.06019.01
5.4.160.0070.06018.88
5.4.150.0070.07319.00
5.4.140.0070.06316.28
5.4.130.0000.06316.27
5.4.120.0000.06716.27
5.4.110.0000.06016.39
5.4.100.0030.06716.41
5.4.90.0030.06016.48
5.4.80.0100.07016.34
5.4.70.0100.05316.37
5.4.60.0100.06316.40
5.4.50.0000.07716.30
5.4.40.0000.07316.54
5.4.30.0030.06016.25
5.4.20.0000.06316.41
5.4.10.0100.07016.29
5.4.00.0030.06715.72
5.3.290.0030.06714.71
5.3.280.0000.07014.67
5.3.270.0070.06714.67
5.3.260.0030.08714.75
5.3.250.0070.07014.74
5.3.240.0070.07314.67
5.3.230.0000.08014.73
5.3.220.0030.06714.67
5.3.210.0100.07014.67
5.3.200.0000.05714.67
5.3.190.0070.07014.67
5.3.180.0000.06314.67
5.3.170.0030.07314.67
5.3.160.0030.04314.71
5.3.150.0000.08014.67
5.3.140.0030.05314.67
5.3.130.0070.07014.67
5.3.120.0030.04314.67
5.3.110.0000.05714.68
5.3.100.0030.06714.67
5.3.90.0000.07014.67
5.3.80.0030.07314.67
5.3.70.0000.08014.67
5.3.60.0000.07014.67
5.3.50.0030.06014.67
5.3.40.0070.04014.67
5.3.30.0030.04014.67
5.3.20.0000.06714.67
5.3.10.0030.07014.67
5.3.00.0030.06314.67
5.2.170.0170.05314.67
5.2.160.0000.05714.67
5.2.150.0000.03314.67
5.2.140.0070.03714.67
5.2.130.0000.05314.67
5.2.120.0030.05314.67
5.2.110.0000.05314.67
5.2.100.0000.06314.67
5.2.90.0030.05714.67
5.2.80.0000.06014.67
5.2.70.0100.04314.67
5.2.60.0070.05714.67
5.2.50.0000.06014.67
5.2.40.0070.06014.67
5.2.30.0000.06314.67
5.2.20.0030.06014.67
5.2.10.0000.05714.67
5.2.00.0070.04014.67
5.1.60.0030.05014.67
5.1.50.0000.05314.67
5.1.40.0000.05314.67
5.1.30.0070.05014.67
5.1.20.0030.04714.67
5.1.10.0000.04714.67
5.1.00.0030.05314.67
5.0.50.0100.04014.67
5.0.40.0070.02714.67
5.0.30.0000.06314.67
5.0.20.0070.04014.67
5.0.10.0070.03314.67
5.0.00.0030.05014.67
4.4.90.0000.03714.67
4.4.80.0030.03314.67
4.4.70.0070.01714.67
4.4.60.0070.02314.67
4.4.50.0030.03714.67
4.4.40.0030.05014.67
4.4.30.0070.02714.67
4.4.20.0030.03314.67
4.4.10.0000.04014.67
4.4.00.0000.05314.67
4.3.110.0000.03714.67
4.3.100.0000.03014.67
4.3.90.0000.03714.67
4.3.80.0030.04014.67
4.3.70.0000.03014.67
4.3.60.0030.03014.67
4.3.50.0000.03314.67
4.3.40.0000.05314.67
4.3.30.0000.03314.67
4.3.20.0000.03714.67
4.3.10.0030.03314.67
4.3.00.0030.03014.67

preferences:
79.85 ms | 401 KiB | 5 Q