3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function removeExtraCharacters($key) { $str = ""; $i = 0; while ($i < strlen($key)) { if (strpos($str, $key[$i]) === false) { $str .= $key[$i]; } $i++; } return $str; } function saveDataFormatMessage($data,$key) { $i = 0; $key = removeExtraCharacters($key); $str = $data.""; $rtn = ""; while ($i < strlen($str)) { $char = $str[$i]; echo $char." - ".intval($char)."\n"; $rtn .= substr($key,intval($char),1); $i++; } return $rtn; } echo saveDataFormatMessage(985651278,md5(""))."\n";
Output for 4.3.0 - 5.6.28, 7.0.0 - 7.1.0
9 - 9 8 - 8 5 - 5 6 - 6 5 - 5 1 - 1 2 - 2 7 - 7 8 - 8 2b9f9410b
Output for hhvm-3.12.0

Process exited with code 137.
Output for hhvm-3.10.0

Process exited with code 153.