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.

clie_file.py 239B

1234567891011121314
  1. import socket
  2. eingabe = input("Bitte etwas eingeben: ")
  3. s = socket.socket()
  4. host = socket.gethostname()
  5. port = 12345
  6. s.connect((host, port))
  7. s.send(eingabe.encode('utf-8'))
  8. msgRes = s.recv(1024)
  9. print(msgRes.decode('utf-8'))
  10. s.close()