Diferente pentru blog/probability-shortlist intre reviziile #22 si #25

Nu exista diferente intre titluri.

Diferente intre continut:

# Build a function rand(x, y, r) that returns a uniformly random point in the circle given by the (x,y) center and the r radius. (dropbox interview)
# Build an algorithm that returns a uniform random permutation of numbers 1 to n. (google interview)
# (Reservoir sampling) Given a stream of integers build an algorithm that returns a uniform random sample of size k using O(k) memory. (google interview)
# (Coupon collector’s problem) Suppose a kid wants to collect all the cartoon characters in a kinder surprise series. Given that there are n different characters in total and they are distributed uniformly random. (twitter interview)
# (Coupon collector’s problem) Suppose a kid wants to collect all the cartoon characters in a kinder surprise series. Given that there are n different characters in total and they are distributed uniformly random. What's the average number of kinder eggs he has to buy so that the selection is complete. (twitter interview)
# (Balls and bins problem) m balls are thrown into n bins. Each ball has 1/n probability of falling into each bin. What’s the expected number of empty bins? (twitter interview)
# What’s the average number of times line 4 is executed if p is a random permutation of numbers 1 to n. (pinterest interview)

Diferente intre securitate:

public
protected

Topicul de forum nu a fost schimbat.