You are given a cluster of 10 distributed worker nodes, each holding a shard of a large integer dataset. The total dataset is split across workers (each worker reads its own shard via an index-based read API). You are provided with pre-built communication primitives — send(worker_id, data), recv(), and barrier()…