← royhp.com

Playground

Small interactive web experiments — built to learn, demo, and tinker. Everything runs on-device.

Systems & CS

TCP Latency Lab

A real sliding-window transport sim — tune RTT, loss, jitter, bandwidth and window size, and watch throughput, retransmits and bufferbloat respond.

Protocol sim · Canvas

TLS Handshake Lab

Watch the TLS handshake over an adjustable-latency link — 1.2 vs 1.3 vs 0-RTT — and see why round trips dominate time-to-first-byte.

Protocol sim · Canvas

Consistent Hashing

The ring behind distributed caches and sharded databases — add/remove nodes, tune virtual nodes, and watch keys remap and load rebalance.

Distributed systems

Quorum Lab

A leaderless (Dynamo-style) cluster — tune N, R and W, fail nodes, and see how R + W > N buys consistent reads, and what goes stale when it doesn't.

Distributed systems

Raft Consensus Lab

Leader-based consensus, live — randomized timeouts elect a leader, a log replicates entry by entry. Kill the leader, split the network, watch it heal.

Distributed systems

Cache Eviction Lab

LRU vs LFU vs FIFO vs Belady's optimal on one access stream — dial cache size and skew, and watch the hit rates pull apart.

Systems sim

Pathfinding

Draw walls and watch BFS, Dijkstra and A* race to the goal — the frontier expands, then the shortest path snaps into place.

Algorithms

Sorting Visualizer

Bubble, insertion, merge, quick, heap — race the classic sorts on a bar chart with sound, and watch comparisons and swaps tick up.

Algorithms

Neural Net Playground

A tiny neural network trained live in your browser — pick a dataset, add layers, and watch the decision boundary form as the loss drops.

Machine learning

Developer tools

Graphics & art

Music & audio

Games & toys