Probability, Statistics, Distributed Systems, Software Engineering, Interview Questions.
search. Python implementation: import random def load_balancer(requests): s = sum(requests) # Invert the requests since it is inversely proportional inv_requests = [s-x for x in requests] s = sum(inv_requests) probs = [x/s for x in inv_requests] # Compute the cumulative probabilities cum_probs =