changed output

replaced all echos by write hosts