def reach(h):
 i = h.find('.')
 if (i >= 0):
  b = h[(i + 1):]
  i = b.find('.')
  if (is_HDN(h) and ((i >= 0) or (b == 'local'))):
   return ('.' + b)
 return h

def reach ( h ) : i = h . find ( '.' ) if ( i >= 0 ) : b = h [ ( i + 1 ) : ] i = b . find ( '.' ) if ( is_HDN ( h ) and ( ( i >= 0 ) or ( b == 'local' ) ) ) : return ( '.' + b ) return h
return reach of host h .