Biased coin toss
Suppose you want to generate a sample of heads and tails from a fair coin. However, you only have a biased coin available (meaning the probability of coming up with heads is different than 1/2).
Write a simulation in Python that will use your biased coin to generate a sample of heads/tails as if it were coming from a fair coin.
Subscribe to premium account to see the solution.Get premium now