3v4l.org

run code in 300+ PHP versions simultaneously
<?php echo '<?xml version="1.0" encoding="'.get_option('blog_charset').'"?'.'>'; /** * RSS2 Feed Template for displaying RSS2 Posts feed. * * @package WordPress * TARATUR */ function getLastCategory ($allcategories) { $catArray = explode("\n",$allcategories); $lastCat = $catArray[count($catArray)-2]; return $lastCat; } function transliterate($textCyrillic){ $cyr = array( 'а' ,'б' ,'в' ,'г' ,'д' ,'ѓ' ,'е' ,'ж' ,'з' ,'ѕ' ,'и' ,'ј' ,'к' ,'л' ,'љ' ,'м' ,'н' ,'њ' ,'о' ,'п' ,'р' ,'с' ,'т' ,'ќ' ,'у' ,'ф' ,'х' ,'ц' ,'ч' ,'џ' ,'ш' , 'А' ,'Б' ,'В' ,'Г' ,'Д' ,'Ѓ' ,'Е' ,'Ж' ,'З' ,'Ѕ' ,'И' ,'Ј' ,'К' ,'Л' ,'Љ' ,'М' ,'Н' ,'Њ' ,'О' ,'П' ,'Р' ,'С' ,'Т' ,'Ќ' ,'У' ,'Ф' ,'Х' ,'Ц' ,'Ч' ,'Џ' ,'Ш','„','”','–','…','Р','“'); $lat = array( 'a' ,'b' ,'v' ,'g' ,'d' ,'gj' ,'e' ,'zh' ,'z' ,'dz' ,'i' ,'j' ,'k' ,'l' ,'lj' ,'m' ,'n' ,'nj' ,'o' ,'p' ,'r' ,'s' ,'t' ,'kj' ,'u' ,'f' ,'h' ,'c' ,'ch' ,'dz', 'sh' , 'A' ,'B' ,'V' ,'G' ,'D' ,'Gj' ,'E' ,'Zh' ,'Z' ,'Dz' ,'I' ,'J' ,'K' ,'L' ,'Lj' ,'M' ,'N' ,'Nj' ,'O' ,'P' ,'R' ,'S' ,'T' ,'Kj' ,'U' ,'F' ,'H' ,'C' ,'Ch' ,'Dz', 'Sh' ,'"','"','-','...','R','"'); // Р… Рё РЏ СЃРµ исти return str_replace($cyr, $lat, $textCyrillic); } $smsContent = transliterate(strip_tags($content)); $smsContent = str_replace(array("\r\n", "\n", "\r"), ' ', $smsContent); $smsContent = str_replace("&nbsp;", ' ', $smsContent); $smsContent = str_replace("\xc2\xa0", ' ', $smsContent); $smsContent = preg_replace('!\s+!', ' ', $smsContent); $smsContent = substr($smsContent, 0, 300); $smsContent = substr($smsContent,0,strrpos($smsContent," ")); $smsContent = preg_replace('/[^\00-\255]+/u', '', $smsContent); ?> <SMStext><?php echo $smsContent; ?></SMStext>

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.0090.00617.00
8.3.60.0040.01418.30
8.3.50.0090.01022.11
8.3.40.0040.01118.97
8.3.30.0140.00018.63
8.3.20.0080.00020.16
8.3.10.0000.00821.92
8.3.00.0070.00023.51
8.2.190.0080.00816.77
8.2.180.0150.00018.26
8.2.170.0110.00422.96
8.2.160.0090.00619.16
8.2.150.0080.00024.18
8.2.140.0050.00324.66
8.2.130.0000.00822.08
8.2.120.0040.00426.35
8.2.110.0030.00719.41
8.2.100.0080.00317.72
8.2.90.0040.00419.10
8.2.80.0080.00017.97
8.2.70.0040.00417.63
8.2.60.0000.00917.77
8.2.50.0030.00518.10
8.2.40.0000.00720.29
8.2.30.0060.00319.17
8.2.20.0060.00318.04
8.2.10.0030.00518.04
8.2.00.0030.00318.22
8.1.280.0110.01125.92
8.1.270.0040.00422.31
8.1.260.0040.00426.35
8.1.250.0030.00528.09
8.1.240.0030.00623.96
8.1.230.0070.00417.77
8.1.220.0030.00717.74
8.1.210.0030.00518.77
8.1.200.0060.00317.22
8.1.190.0060.00317.23
8.1.180.0000.00718.10
8.1.170.0040.00718.59
8.1.160.0080.00018.82
8.1.150.0070.00020.25
8.1.140.0040.00419.46
8.1.130.0000.00718.88
8.1.120.0040.00417.29
8.1.110.0040.00417.36
8.1.100.0040.00417.29
8.1.90.0040.00417.35
8.1.80.0000.00817.35
8.1.70.0040.00417.37
8.1.60.0040.00417.42
8.1.50.0020.00517.47
8.1.40.0040.00417.42
8.1.30.0040.00417.54
8.1.20.0000.00717.59
8.1.10.0080.00017.61
8.1.00.0050.00217.55
8.0.300.0040.00418.77
8.0.290.0000.00716.63
8.0.280.0000.00718.43
8.0.270.0000.00717.25
8.0.260.0030.00317.24
8.0.250.0030.00317.05
8.0.240.0030.00317.08
8.0.230.0090.00016.88
8.0.220.0040.00416.97
8.0.210.0000.00916.92
8.0.200.0000.00616.89
8.0.190.0000.00817.01
8.0.180.0040.00416.84
8.0.170.0040.00417.00
8.0.160.0000.00817.01
8.0.150.0070.00316.77
8.0.140.0070.00016.87
8.0.130.0050.00313.36
8.0.120.0050.00216.79
8.0.110.0030.00316.87
8.0.100.0000.00717.00
8.0.90.0050.00316.78
8.0.80.0000.01516.99
8.0.70.0000.00816.97
8.0.60.0040.00416.73
8.0.50.0040.00416.97
8.0.30.0120.00617.09
8.0.20.0110.01017.40
8.0.10.0050.00216.97
8.0.00.0120.00616.55
7.4.330.0070.00015.55
7.4.320.0030.00316.43
7.4.300.0000.00616.59
7.4.290.0000.00716.63
7.4.280.0030.00516.39
7.4.270.0050.00316.50
7.4.260.0000.00716.52
7.4.250.0040.00416.55
7.4.240.0000.00716.48
7.4.230.0030.00316.68
7.4.220.0130.00716.45
7.4.210.0100.00616.41
7.4.200.0000.00716.33
7.4.160.0130.00716.47
7.4.150.0110.01117.40
7.4.140.0140.00617.86
7.4.130.0120.01116.58
7.4.120.0130.01016.58
7.4.110.0070.01016.48
7.4.100.0080.00816.46
7.4.90.0090.00916.69
7.4.80.0070.01119.39
7.4.70.0090.00916.60
7.4.60.0100.00616.40
7.4.50.0040.00816.23
7.4.40.0060.01016.27
7.4.30.0090.00616.42
7.4.00.0120.00315.04
7.3.330.0000.00513.31
7.3.320.0000.00613.38
7.3.310.0030.00316.33
7.3.300.0030.00316.32
7.3.290.0020.01216.35
7.3.280.0090.00916.36
7.3.270.0120.00617.40
7.3.260.0110.00916.49
7.3.250.0160.00516.35
7.3.240.0110.00816.45
7.3.230.0060.01316.59
7.3.210.0110.00616.47
7.3.200.0130.00416.69
7.3.190.0090.00916.62
7.3.180.0040.01216.69
7.3.170.0070.01016.53
7.3.160.0040.01216.59
7.2.330.0070.01116.44
7.2.320.0060.01216.59
7.2.310.0100.00616.75
7.2.300.0130.01016.39
7.2.290.0030.01316.34
7.2.60.0030.01016.86
7.2.00.0070.00719.43
7.1.200.0030.00915.41
7.1.100.0030.00917.78
7.1.70.0030.00317.13
7.1.60.0030.01017.28
7.1.50.0160.01016.53
7.1.30.2930.09336.55
7.1.20.2400.06336.52
7.1.10.2730.06320.32
7.1.00.3470.09020.63
7.0.200.0100.00616.40
7.0.170.2030.05720.07
7.0.160.2730.06320.08
7.0.150.2600.06020.07
7.0.140.3230.04720.03
7.0.130.2730.06320.25
7.0.120.3170.07320.05
7.0.110.3930.08320.23
7.0.100.0030.06319.97
7.0.90.0070.09020.12
7.0.80.0130.06020.18
7.0.70.2970.06020.11
7.0.60.2930.05319.87
7.0.50.0070.06720.24
7.0.40.0370.06720.23
7.0.30.0130.07320.00
7.0.20.4030.07720.22
7.0.10.4270.06320.07
7.0.00.3200.07720.07

preferences:
44.98 ms | 401 KiB | 5 Q