WorldQuant Interview Question

Simulate fair coin with unfair coins