armantik.com / lab

The Learning Lab

Interactive guides I use for learning and mentoring. Three tracks: system design, algorithms and Java. In the algorithm guides you press Next and watch the data structure change while the matching Java lines light up; the system design guides have simulators to play with, and the Java guides are for looking things up. Everything runs in the browser and lives on this site.

System designAlgorithmsJava

/lab/system-design

System design

How real systems are put together: scaling from one server to millions, rate limiting, and the patterns behind AI systems.

Case studies

Case study V.1URL shortenerBase62 codes from leased ID ranges, a cache in front of the store, and a 302 redirect.BasicCase study V.2News feedPush, pull or the hybrid every large feed uses, and what one post really costs.IntermediateCase study V.3Chat systemWebSockets, Snowflake IDs and inbox queues, for users who are online or offline.IntermediateCase study V.4Notification systemThree channels and flaky providers: keep the channels apart and retry without sending twice.IntermediateCase study V.5Search autocompleteA request on every keystroke: rank offline, then answer each prefix in milliseconds.IntermediateCase study V.6Web crawlerFetch a billion pages politely, and never fetch or store the same page twice.IntermediateCase study V.7Nearby placesDatabases index one dimension well and location has two: a geohash or a quadtree fixes that.IntermediateCase study V.8Ticket bookingThousands want the same seat in the same second, and exactly one buyer gets it.AdvancedCase study V.9Ride sharingHundreds of thousands of location updates a second, and no driver gets two rides.AdvancedCase study V.10Video streamingSpend compute once at upload to save bandwidth on every view.AdvancedCase study V.11File syncContent hashed blocks, deduplication, and two edits at once that become a copy.AdvancedCase study V.12Collaborative editorSeveral people type into one paragraph, and everyone ends up with the same text.AdvancedCase study V.13Distributed key value storeDynamo piece by piece: partitions, quorums, vector clocks and what happens when nodes fail.AdvancedCase study V.14Payment systemLow throughput, zero tolerance: never charge twice and never lose money.Advanced

/lab/algorithms

Algorithms

The basic data structures, then classic coding problems, each solved several ways and run step by step next to the Java code. Links point to the problem statements; the solutions are my own.

AlgorithmsBasic Data StructuresArrays, lists, stacks, queues, hash tables, trees, heaps, graphs and tries, each drawn by hand with what every operation costs and the Java class to use.10 structuresdrawn by handAlgorithmsBFS and DFSBreadth first and depth first search on a graph and a tree. The queue or the stack is the only real difference.graph and treefoundations

/lab/java

/lab/new-joiners

New to the team? Start here

If you're joining a backend team, this order works well: Basic Data Structures, BFS and DFS and Java Collections for the everyday building blocks, then LRU and LFU Cache and Rate Limiter for the patterns you'll meet in production, then the System Design Casebook to put it together.

Most guides are built with Claude from my own Java solutions. Spotted a mistake? Tell me.