3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function reverse($str) { $ret = ''; for ($i = mb_strlen($str)-1; $i >= 0; $i--) { $ret .= mb_substr($str, $i, 1); } return $ret; } function oddList($x) { return implode(', ', range(1, $x, 2)); } echo reverse('ābc');
Output for 5.6.0 - 7.1.0
cbā
Output for 4.3.0 - 5.5.37
cb��