From b707eed9ce3c9bc8009fccdb486dea048d921092 Mon Sep 17 00:00:00 2001 From: herrerahuezoul67409 Date: Tue, 15 Oct 2019 15:29:59 +0200 Subject: [PATCH] letztes commit --- .idea/vcs.xml | 6 ++++++ client.py | 17 +++++++++++------ server.py | 5 +++-- 3 files changed, 20 insertions(+), 8 deletions(-) create mode 100644 .idea/vcs.xml diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..94a25f7 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/client.py b/client.py index 23ca4f6..2c308fe 100644 --- a/client.py +++ b/client.py @@ -3,12 +3,17 @@ import socket s = socket.socket() host = socket.gethostname() port = 12345 -s.bind((host,port)) -s.listen() + + +eingabe = input("gibt etwas ein") +print(eingabe) + + while True: (connection, addr) = s.accept() - print("Verdindung von", addr) - msg= "Danke für ds vorbeischauen" - connection.send(msg.encode('utf-8')) - connection.close() \ No newline at end of file + connection.send(eingabe.encode('utf-8')) + connection.close() + + + diff --git a/server.py b/server.py index 48b27f5..82fa659 100644 --- a/server.py +++ b/server.py @@ -3,9 +3,10 @@ import socket s = socket.socket() host = socket.gethostname() port = 12345 -#eingabe = "hello" +s.bind((host,port)) +s.listen() s.connect((host, port)) bytes = s.recv(1024) print(bytes.decode('utf-8')) -s.close() \ No newline at end of file +s.close()