Verified interview challenge
Distributed Mode and Median
Find global statistics when each worker can see only its own data and communicate through messages.
Unlock with Full AccessThe challenge
Implement the global mode, then add an exact median calculation in the same Python file. Each worker receives a local shard and supplied send and receive functions. Follow-up discussions explore communication costs, uneven data and different value distributions. Choose guided practice or a 55-minute practice timer.
What you'll practise
Global aggregation
Combine local information without losing values that matter to the global answer.
Message coordination
Design a protocol that works across empty and uneven worker shards.
Communication costs
Compare how your approach moves data as its size and distribution change.
# Build on your implementation
# Run checks for the current part
# Full starter code includedRun your code to see results.