PTR by Chiether

<?while($a=trim(fgets(STDIN))){$h="in-addr";$c=array_reverse(explode('.',$a));if(!$d=strpos($a,'.')){foreach(explode(':',str_replace('::',str_repeat(':',9-substr_count($a,':')),$a))as$b)$d.=sprintf('%04s',$b);$c=array_reverse(str_split($d));$h='ip6';}echo implode('.',$c).".$h.arpa\n";}

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page