3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = "abc"; $chars = array_map("ord", str_split($str, 1)); printf(str_repeat("\\x%x", strlen($str)), ...$chars);;

preferences:
65.83 ms | 1746 KiB | 5 Q