Fleetcode
A real-time 1v1 battle platform where competitive programming enthusiasts go head-to-head for glory.
Created on 29th May 2025
•
Fleetcode
A real-time 1v1 battle platform where competitive programming enthusiasts go head-to-head for glory.
The problem Fleetcode solves
While platforms like LeetCode and Codeforces are excellent for practice and contests, they lack real-time 1v1 competition, which many competitive programming enthusiasts crave. There's no easy way to instantly challenge another coder, solve the same problem in parallel, and truly compete.
Fleetcode solves this by offering:
Instant 1v1 matchmaking with a fair problem
A real-time synced timer
An integrated code editor and problem panel
Automatic winner declaration based on submission and correctness
This mirrors the thrill of a coding round — in a controlled, focused 1v1 format. No waiting for contests. No leaderboard grinding. Just raw competition, anytime.
It transforms passive practice into engaging duels — ideal for those preparing for coding competitions or simply looking to sharpen their edge.
Challenges we ran into
Building Fleetcode, a real-time 1v1 competitive programming platform came with multiple technical hurdles. The platform is still in its development phase, with core systems implemented and integration underway.
-
WebSocket Synchronization
Early issues with timers and game state desync led to confusion during matches. We solved this by creating a centralized timer on the backend that broadcasts updates every second via WebSockets to both players. -
Matchmaking System
We initially faced problems like self-matching and stalled queues. We implemented a FIFO-based matchmaking queue using a /match/find API. The logic is written, and frontend integration is ongoing. -
Code Editor Isolation
Using a shared or global editor state caused unexpected behavior. We integrated Monaco Editor and scoped it per user session to maintain isolated environments. -
Winner Declaration Logic
Edge cases like simultaneous submissions or no submissions required special handling. Backend logic now tracks valid submissions and determines winners or declares a draw if time runs out. -
UI/UX Challenges
Dark theme design needed multiple iterations to balance readability and focus. We used TailwindCSS to build a responsive, distraction-free interface suitable for high-stakes 1v1 battles.
We’re actively integrating the judge system, completing matchmaking UI flow, and adding user stats, rankings, and match history.
Technologies used
