You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

client.py 270B

12345678910111213
  1. import socket
  2. s = socket.socket()
  3. host = socket.gethostname()
  4. port = 22445
  5. s.connect((host, port))
  6. message = input('eingabe: ')
  7. #bytes = s.sendmsg(message.encode('utf-8'))
  8. test = s.send(message.encode('utf-8'))
  9. msg = s.recv(1024)
  10. print (msg.decode('utf-8'))
  11. s.close()