3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $string='sadfsakfjbsadjkfhsadkjfhasdlkjhfksahjksdhfkjasdhflkjashfkjshadkfjhsakldfjhsakf'; $time=microtime(true); for($i=0;$i<1000;$i++) removeaccents1($string); $time=microtime(true)-$time; echo "New took $time seconds\n"; $time=microtime(true); for($i=0;$i<1000;$i++) removeaccents2($string); $time=microtime(true)-$time; echo "Old took $time seconds\n"; function removeaccents1($string) { return utf8_encode(strtr(utf8_decode($string),utf8_decode('ŠŒŽšœžŸ¥µÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖØÙÚÛÜÝßàáâãäåæçèéêëìíîïðñòóôõöøùúûüýÿ'),'SOZsozYYuAAAAAAACEEEEIIIIDNOOOOOOUUUUYsaaaaaaaceeeeiiiionoooooouuuuyy')); } function removeaccents2($string) { return strtr($string,'ŠŒŽšœžŸ¥µÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖØÙÚÛÜÝßàáâãäåæçèéêëìíîïðñòóôõöøùúûüýÿ','SOZsozYYuAAAAAAACEEEEIIIIDNOOOOOOUUUUYsaaaaaaaceeeeiiiionoooooouuuuyy'); }
Output for 7.1.0
New took 0.0012810230255127 seconds Old took 0.00029206275939941 seconds
Output for 7.0.14
New took 0.0022361278533936 seconds Old took 0.00045394897460938 seconds
Output for 7.0.10
New took 0.0030148029327393 seconds Old took 0.00068211555480957 seconds
Output for 7.0.9
New took 0.0012569427490234 seconds Old took 0.00029110908508301 seconds
Output for 7.0.8
New took 0.0017740726470947 seconds Old took 0.00041484832763672 seconds
Output for 7.0.7
New took 0.0012321472167969 seconds Old took 0.00029683113098145 seconds
Output for 7.0.6
New took 0.0018429756164551 seconds Old took 0.00041484832763672 seconds
Output for 7.0.5
New took 0.0017330646514893 seconds Old took 0.00039196014404297 seconds
Output for 7.0.4
New took 0.0019750595092773 seconds Old took 0.00042605400085449 seconds
Output for 7.0.3
New took 0.0017518997192383 seconds Old took 0.00037908554077148 seconds
Output for 7.0.2
New took 0.002122163772583 seconds Old took 0.00047707557678223 seconds
Output for 7.0.1
New took 0.002079963684082 seconds Old took 0.00043201446533203 seconds
Output for 7.0.0
New took 0.0018579959869385 seconds Old took 0.00041508674621582 seconds
Output for hhvm-3.12.0
New took 0.0016849040985107 seconds Old took 0.00049901008605957 seconds
Output for hhvm-3.10.0
New took 0.00199294090271 seconds Old took 0.00064587593078613 seconds
Output for 5.6.28
New took 0.0029129981994629 seconds Old took 0.00080609321594238 seconds
Output for 5.6.25
New took 0.0025320053100586 seconds Old took 0.00065112113952637 seconds
Output for 5.6.24
New took 0.002295970916748 seconds Old took 0.00059390068054199 seconds
Output for 5.6.23
New took 0.0021209716796875 seconds Old took 0.00058484077453613 seconds
Output for 5.6.22
New took 0.0015530586242676 seconds Old took 0.00041007995605469 seconds
Output for 5.6.21
New took 0.0023341178894043 seconds Old took 0.00060009956359863 seconds
Output for 5.6.20
New took 0.0015828609466553 seconds Old took 0.00042319297790527 seconds
Output for 5.6.19
New took 0.0021359920501709 seconds Old took 0.00054502487182617 seconds
Output for 5.6.18
New took 0.0027220249176025 seconds Old took 0.00067710876464844 seconds
Output for 5.6.17
New took 0.0025029182434082 seconds Old took 0.00063705444335938 seconds
Output for 5.6.16
New took 0.0028021335601807 seconds Old took 0.00071501731872559 seconds
Output for 5.6.15
New took 0.0017797946929932 seconds Old took 0.00055789947509766 seconds
Output for 5.6.14
New took 0.002392053604126 seconds Old took 0.00059795379638672 seconds
Output for 5.6.13
New took 0.0025789737701416 seconds Old took 0.00083804130554199 seconds
Output for 5.6.12
New took 0.0024280548095703 seconds Old took 0.00060296058654785 seconds
Output for 5.6.11
New took 0.0023560523986816 seconds Old took 0.00060701370239258 seconds
Output for 5.6.10
New took 0.0017910003662109 seconds Old took 0.00047707557678223 seconds
Output for 5.6.9
New took 0.0016288757324219 seconds Old took 0.00040006637573242 seconds
Output for 5.6.8
New took 0.0013470649719238 seconds Old took 0.00032806396484375 seconds
Output for 5.6.7
New took 0.0016219615936279 seconds Old took 0.00040888786315918 seconds
Output for 5.6.6
New took 0.0013349056243896 seconds Old took 0.0003511905670166 seconds
Output for 5.6.5
New took 0.0021429061889648 seconds Old took 0.00052595138549805 seconds
Output for 5.6.4
New took 0.0019419193267822 seconds Old took 0.00041103363037109 seconds
Output for 5.6.3
New took 0.0022580623626709 seconds Old took 0.0005640983581543 seconds
Output for 5.6.2
New took 0.0017600059509277 seconds Old took 0.00035715103149414 seconds
Output for 5.6.1
New took 0.00164794921875 seconds Old took 0.00041007995605469 seconds
Output for 5.6.0
New took 0.0016250610351562 seconds Old took 0.00040602684020996 seconds
Output for 5.5.38
New took 0.002439022064209 seconds Old took 0.00074982643127441 seconds
Output for 5.5.37
New took 0.002284049987793 seconds Old took 0.00054287910461426 seconds
Output for 5.5.36
New took 0.0019700527191162 seconds Old took 0.00047612190246582 seconds
Output for 5.5.35
New took 0.0018460750579834 seconds Old took 0.00055193901062012 seconds
Output for 5.5.34
New took 0.001615047454834 seconds Old took 0.0004270076751709 seconds
Output for 5.5.33
New took 0.0022139549255371 seconds Old took 0.00054216384887695 seconds
Output for 5.5.32
New took 0.0021729469299316 seconds Old took 0.00054693222045898 seconds
Output for 5.5.31
New took 0.0017459392547607 seconds Old took 0.00043606758117676 seconds
Output for 5.5.30
New took 0.0023839473724365 seconds Old took 0.00046610832214355 seconds
Output for 5.5.29
New took 0.0046989917755127 seconds Old took 0.00061511993408203 seconds
Output for 5.5.28
New took 0.0024068355560303 seconds Old took 0.00061678886413574 seconds
Output for 5.5.27
New took 0.0016531944274902 seconds Old took 0.0004279613494873 seconds
Output for 5.5.26
New took 0.002255916595459 seconds Old took 0.0006260871887207 seconds
Output for 5.5.25
New took 0.0026140213012695 seconds Old took 0.00069713592529297 seconds
Output for 5.5.24
New took 0.0013470649719238 seconds Old took 0.00037288665771484 seconds
Output for 5.5.23
New took 0.0017368793487549 seconds Old took 0.00044083595275879 seconds
Output for 5.5.22
New took 0.0018200874328613 seconds Old took 0.00046610832214355 seconds
Output for 5.5.21
New took 0.0014328956604004 seconds Old took 0.00034403800964355 seconds
Output for 5.5.20
New took 0.0023272037506104 seconds Old took 0.00059199333190918 seconds
Output for 5.5.19
New took 0.0027701854705811 seconds Old took 0.00072193145751953 seconds
Output for 5.5.18
New took 0.0016000270843506 seconds Old took 0.00041699409484863 seconds
Output for 5.5.16
New took 0.0014657974243164 seconds Old took 0.00039100646972656 seconds
Output for 5.5.15
New took 0.0026791095733643 seconds Old took 0.00066995620727539 seconds
Output for 5.5.14
New took 0.0026650428771973 seconds Old took 0.00065803527832031 seconds
Output for 5.5.13
New took 0.0016429424285889 seconds Old took 0.00042891502380371 seconds
Output for 5.5.12
New took 0.0016450881958008 seconds Old took 0.00043201446533203 seconds
Output for 5.5.11
New took 0.0016341209411621 seconds Old took 0.00044083595275879 seconds
Output for 5.5.10
New took 0.0017561912536621 seconds Old took 0.00059604644775391 seconds
Output for 5.5.9
New took 0.0013980865478516 seconds Old took 0.00038003921508789 seconds
Output for 5.5.8
New took 0.0017662048339844 seconds Old took 0.00047516822814941 seconds
Output for 5.5.7
New took 0.0017669200897217 seconds Old took 0.00046396255493164 seconds
Output for 5.5.6
New took 0.0015840530395508 seconds Old took 0.00040602684020996 seconds
Output for 5.5.5
New took 0.0015799999237061 seconds Old took 0.00041699409484863 seconds
Output for 5.5.4
New took 0.0027668476104736 seconds Old took 0.00085186958312988 seconds
Output for 5.5.3
New took 0.0016038417816162 seconds Old took 0.00041294097900391 seconds
Output for 5.5.2
New took 0.0016810894012451 seconds Old took 0.00045585632324219 seconds
Output for 5.5.1
New took 0.003093957901001 seconds Old took 0.00086402893066406 seconds
Output for 5.5.0
New took 0.0016298294067383 seconds Old took 0.00041604042053223 seconds
Output for 5.4.45
New took 0.0017178058624268 seconds Old took 0.00043988227844238 seconds
Output for 5.4.44
New took 0.0023748874664307 seconds Old took 0.00061702728271484 seconds
Output for 5.4.43
New took 0.0025708675384521 seconds Old took 0.00064301490783691 seconds
Output for 5.4.42
New took 0.0016088485717773 seconds Old took 0.00039911270141602 seconds
Output for 5.4.41
New took 0.0019328594207764 seconds Old took 0.00040197372436523 seconds
Output for 5.4.40
New took 0.0016369819641113 seconds Old took 0.0004119873046875 seconds
Output for 5.4.39
New took 0.0019211769104004 seconds Old took 0.0003960132598877 seconds
Output for 5.4.38
New took 0.0012831687927246 seconds Old took 0.00032901763916016 seconds
Output for 5.4.37
New took 0.0013351440429688 seconds Old took 0.0003359317779541 seconds
Output for 5.4.36
New took 0.0017440319061279 seconds Old took 0.00049614906311035 seconds
Output for 5.4.35
New took 0.0014371871948242 seconds Old took 0.00035595893859863 seconds
Output for 5.4.34
New took 0.0016231536865234 seconds Old took 0.00045609474182129 seconds
Output for 5.4.32
New took 0.0015430450439453 seconds Old took 0.0003960132598877 seconds
Output for 5.4.31
New took 0.0015499591827393 seconds Old took 0.00042009353637695 seconds
Output for 5.4.30
New took 0.0017669200897217 seconds Old took 0.00044417381286621 seconds
Output for 5.4.29
New took 0.001561164855957 seconds Old took 0.00039911270141602 seconds
Output for 5.4.28
New took 0.0015881061553955 seconds Old took 0.00040102005004883 seconds
Output for 5.4.27
New took 0.0015630722045898 seconds Old took 0.0004119873046875 seconds
Output for 5.4.26
New took 0.0015640258789062 seconds Old took 0.00040507316589355 seconds
Output for 5.4.25
New took 0.001600980758667 seconds Old took 0.00040984153747559 seconds
Output for 5.4.24
New took 0.0018539428710938 seconds Old took 0.00046300888061523 seconds
Output for 5.4.23
New took 0.0030519962310791 seconds Old took 0.00050210952758789 seconds
Output for 5.4.22
New took 0.0018320083618164 seconds Old took 0.00046014785766602 seconds
Output for 5.4.21
New took 0.0021309852600098 seconds Old took 0.00055789947509766 seconds
Output for 5.4.20
New took 0.001655101776123 seconds Old took 0.00041103363037109 seconds
Output for 5.4.19
New took 0.0015761852264404 seconds Old took 0.0003969669342041 seconds
Output for 5.4.18
New took 0.002540111541748 seconds Old took 0.0006568431854248 seconds
Output for 5.4.17
New took 0.0014081001281738 seconds Old took 0.0003819465637207 seconds
Output for 5.4.16
New took 0.0024449825286865 seconds Old took 0.00067710876464844 seconds
Output for 5.4.15
New took 0.0014951229095459 seconds Old took 0.00037217140197754 seconds
Output for 5.4.14
New took 0.0019087791442871 seconds Old took 0.00049591064453125 seconds
Output for 5.4.13
New took 0.0023200511932373 seconds Old took 0.00059103965759277 seconds
Output for 5.4.12
New took 0.0027258396148682 seconds Old took 0.00068902969360352 seconds
Output for 5.4.11
New took 0.0024399757385254 seconds Old took 0.00065398216247559 seconds
Output for 5.4.10
New took 0.0025999546051025 seconds Old took 0.0006568431854248 seconds
Output for 5.4.9
New took 0.0022320747375488 seconds Old took 0.00048995018005371 seconds
Output for 5.4.8
New took 0.0027859210968018 seconds Old took 0.00069093704223633 seconds
Output for 5.4.7
New took 0.0022420883178711 seconds Old took 0.00058412551879883 seconds
Output for 5.4.6
New took 0.0017979145050049 seconds Old took 0.0003969669342041 seconds
Output for 5.4.5
New took 0.0022389888763428 seconds Old took 0.00055909156799316 seconds
Output for 5.4.4
New took 0.0022389888763428 seconds Old took 0.00059986114501953 seconds
Output for 5.4.3
New took 0.0021939277648926 seconds Old took 0.00057697296142578 seconds
Output for 5.4.2
New took 0.001906156539917 seconds Old took 0.00048685073852539 seconds
Output for 5.4.1
New took 0.002000093460083 seconds Old took 0.00050997734069824 seconds
Output for 5.4.0
New took 0.0022220611572266 seconds Old took 0.00055503845214844 seconds
Output for 5.3.29
New took 0.0017380714416504 seconds Old took 0.0005650520324707 seconds
Output for 5.3.28
New took 0.0017490386962891 seconds Old took 0.00063610076904297 seconds
Output for 5.3.27
New took 0.002000093460083 seconds Old took 0.00057387351989746 seconds
Output for 5.3.26
New took 0.0017409324645996 seconds Old took 0.00057601928710938 seconds
Output for 5.3.25
New took 0.0025789737701416 seconds Old took 0.00083303451538086 seconds
Output for 5.3.24
New took 0.0031559467315674 seconds Old took 0.0013070106506348 seconds
Output for 5.3.23
New took 0.0030090808868408 seconds Old took 0.00096392631530762 seconds
Output for 5.3.22
New took 0.0026900768280029 seconds Old took 0.00089597702026367 seconds
Output for 5.3.21
New took 0.0025789737701416 seconds Old took 0.00088095664978027 seconds
Output for 5.3.20
New took 0.002842903137207 seconds Old took 0.00093984603881836 seconds
Output for 5.3.19
New took 0.0018630027770996 seconds Old took 0.00059199333190918 seconds
Output for 5.3.18
New took 0.0026400089263916 seconds Old took 0.00084590911865234 seconds
Output for 5.3.17
New took 0.0023250579833984 seconds Old took 0.0006859302520752 seconds
Output for 5.3.16
New took 0.0030190944671631 seconds Old took 0.0009911060333252 seconds
Output for 5.3.15
New took 0.0031929016113281 seconds Old took 0.0010612010955811 seconds
Output for 5.3.14
New took 0.0032141208648682 seconds Old took 0.0015780925750732 seconds
Output for 5.3.13
New took 0.0026941299438477 seconds Old took 0.00090789794921875 seconds
Output for 5.3.12
New took 0.0026109218597412 seconds Old took 0.00094819068908691 seconds
Output for 5.3.11
New took 0.0022220611572266 seconds Old took 0.00081515312194824 seconds
Output for 5.3.10
New took 0.0017540454864502 seconds Old took 0.00057816505432129 seconds
Output for 5.3.9
New took 0.0022900104522705 seconds Old took 0.00074315071105957 seconds
Output for 5.3.8
New took 0.0025908946990967 seconds Old took 0.00083708763122559 seconds
Output for 5.3.7
New took 0.002161979675293 seconds Old took 0.00070691108703613 seconds
Output for 5.3.6
New took 0.0018408298492432 seconds Old took 0.00060296058654785 seconds
Output for 5.3.5
New took 0.00325608253479 seconds Old took 0.0010590553283691 seconds
Output for 5.3.4
New took 0.0029358863830566 seconds Old took 0.00066781044006348 seconds
Output for 5.3.3
New took 0.0047128200531006 seconds Old took 0.0011210441589355 seconds
Output for 5.3.2
New took 0.0018539428710938 seconds Old took 0.00063109397888184 seconds
Output for 5.3.1
New took 0.0022900104522705 seconds Old took 0.0006258487701416 seconds
Output for 5.3.0
New took 0.0027611255645752 seconds Old took 0.00091195106506348 seconds
Output for 5.2.17
New took 0.0032260417938232 seconds Old took 0.0010879039764404 seconds
Output for 5.2.16
New took 0.0026810169219971 seconds Old took 0.00089788436889648 seconds
Output for 5.2.15
New took 0.0036511421203613 seconds Old took 0.0012609958648682 seconds
Output for 5.2.14
New took 0.0030438899993896 seconds Old took 0.0010859966278076 seconds
Output for 5.2.13
New took 0.0030269622802734 seconds Old took 0.0011110305786133 seconds
Output for 5.2.12
New took 0.0033221244812012 seconds Old took 0.0011129379272461 seconds
Output for 5.2.11
New took 0.0033841133117676 seconds Old took 0.0011739730834961 seconds
Output for 5.2.10
New took 0.0023670196533203 seconds Old took 0.00084090232849121 seconds
Output for 5.2.9
New took 0.0028891563415527 seconds Old took 0.0013399124145508 seconds
Output for 5.2.8
New took 0.0031328201293945 seconds Old took 0.0010809898376465 seconds
Output for 5.2.7
New took 0.0029599666595459 seconds Old took 0.0012869834899902 seconds
Output for 5.2.6
New took 0.0032470226287842 seconds Old took 0.0011258125305176 seconds
Output for 5.2.5
New took 0.0028421878814697 seconds Old took 0.00078701972961426 seconds
Output for 5.2.4
New took 0.0019731521606445 seconds Old took 0.00065708160400391 seconds
Output for 5.2.3
New took 0.0026750564575195 seconds Old took 0.00085210800170898 seconds
Output for 5.2.2
New took 0.0032761096954346 seconds Old took 0.0010778903961182 seconds
Output for 5.2.1
New took 0.00189208984375 seconds Old took 0.00067901611328125 seconds
Output for 5.2.0
New took 0.0029830932617188 seconds Old took 0.0010020732879639 seconds
Output for 5.1.6
New took 0.002032995223999 seconds Old took 0.00065898895263672 seconds
Output for 5.1.5
New took 0.0022518634796143 seconds Old took 0.00074601173400879 seconds
Output for 5.1.4
New took 0.0037961006164551 seconds Old took 0.0012400150299072 seconds
Output for 5.1.3
New took 0.0035312175750732 seconds Old took 0.0011560916900635 seconds
Output for 5.1.2
New took 0.0025210380554199 seconds Old took 0.00078701972961426 seconds
Output for 5.1.1
New took 0.0034928321838379 seconds Old took 0.0010080337524414 seconds
Output for 5.1.0
New took 0.0036120414733887 seconds Old took 0.0012001991271973 seconds
Output for 5.0.5
New took 0.0041711330413818 seconds Old took 0.0015687942504883 seconds
Output for 5.0.4
New took 0.00459885597229 seconds Old took 0.0016369819641113 seconds
Output for 5.0.3
New took 0.0063879489898682 seconds Old took 0.0025420188903809 seconds
Output for 5.0.2
New took 0.0031890869140625 seconds Old took 0.0012149810791016 seconds
Output for 5.0.1
New took 0.0025629997253418 seconds Old took 0.00094914436340332 seconds
Output for 5.0.0
New took 0.0037970542907715 seconds Old took 0.0015170574188232 seconds
Output for 4.4.9
New took 0.003907 seconds Old took 0.001526 seconds
Output for 4.4.8
New took 0.004053 seconds Old took 0.001639 seconds
Output for 4.4.7
New took 0.003265 seconds Old took 0.001308 seconds
Output for 4.4.6
New took 0.004631 seconds Old took 0.00186 seconds
Output for 4.4.5
New took 0.004048 seconds Old took 0.001517 seconds
Output for 4.4.4
New took 0.002584 seconds Old took 0.001107 seconds
Output for 4.4.3
New took 0.00564 seconds Old took 0.002522 seconds
Output for 4.4.2
New took 0.003353 seconds Old took 0.001444 seconds
Output for 4.4.1
New took 0.004351 seconds Old took 0.00176 seconds
Output for 4.4.0
New took 0.003174 seconds Old took 0.001104 seconds
Output for 4.3.11
New took 0.004355 seconds Old took 0.001705 seconds
Output for 4.3.10
New took 0.002442 seconds Old took 0.00096 seconds
Output for 4.3.9
New took 0.00251 seconds Old took 0.001008 seconds
Output for 4.3.8
New took 0.004082 seconds Old took 0.001732 seconds
Output for 4.3.7
New took 0.003386 seconds Old took 0.001343 seconds
Output for 4.3.6
New took 0.003793 seconds Old took 0.00147 seconds
Output for 4.3.5
New took 0.002956 seconds Old took 0.001298 seconds
Output for 4.3.4
New took 0.004087 seconds Old took 0.001606 seconds
Output for 4.3.3
New took 0.004122 seconds Old took 0.001696 seconds
Output for 4.3.2
New took 0.004185 seconds Old took 0.001801 seconds
Output for 4.3.1
New took 0.004567 seconds Old took 0.001799 seconds
Output for 4.3.0
New took 0.003722 seconds Old took 0.001454 seconds