This project is a chat room with one server and multiple clients. The server provides a chat room for clients to join. After joining the chat, the clients can send messages to the chat room where all chat messages are logged and displayed.
- Open a terminal and create a chat room by running Server.py
cd <root>
python Server.py
- In another terminal, create and add a client to the chat room by running Client.py
python Client.py [name] # Don't forget to declare the client's name
-
You can add more clients in the room by running more Client.py in more terminals.
-
Let's have a chat!
- First, open 3 terminals and run the code as following.
- Send messages from Person_A and Person_B to the chat room. Everyone in the room received messages immediately.