PROJECT / Network programming
Networked Quiz Game
A Kahoot-style multiplayer trivia game over TCP: one threaded Python server, many clients, a text protocol and a live scoreboard.
- Python
- TCP sockets
- Threading
- Type
- Systems
- Source
- Public on GitHub
- Role
- Built with Emraan Kafihi.
- Built with
- Python, TCP sockets, Threading
01 / Overview
Overview
Server
Listens for TCP connections, sends synchronized questions, checks answers, keeps the scoreboard and announces the winner.
Clients
Register a player name, show multiple-choice questions, send answers and display score feedback.
Protocol
Plain text messages such as QUESTION and ROUND_SUMMARY, readable by people and programs.
02 / Context and problem
Context and problem
COMP 2100 Network Programming at Wentworth, Fall 2025.
03 / My role
My role
Built with Emraan Kafihi.
04 / How it works
How it works
Connect
Each client connects and the server registers a Player object with its own name, score and streams.
Thread per player
Each connection runs on its own thread, so the server talks to many clients without blocking.
Text streams
makefile() turns the socket into a text stream, so readline() and write() work like a file.
Rounds
The server broadcasts questions, collects answers, handles timeouts and disconnects, and sends round summaries.
05 / Key decisions
Key decisions
TCP
Ordered, reliable delivery, so a quiz never sees lost or out-of-order messages.
Python
Clean, readable sockets and a language the whole class already knew.
06 / Results and numbers
Results and numbers
Demoed live in class (COMP 2100 Network Programming, Fall 2025).
- Multiplayer quiz over raw TCP sockets.
07 / What I learned
What I learned
- Hard cases: clients disconnecting mid-question, buffered lines arriving out of order, the server not flushing output, and broadcasting to closed sockets.
08 / What's next
What's next
- Buzzer mode, a final scoreboard screen, a total-wins tracker and more question categories.
09 / Next project