โ† Amazon questions

Fair coin toss from biased function

Filed under Amazon

Given a biased coin function f() that outputs 0 with probability 0.4 and 1 with probability 0.6, design a fair coin function f1() that outputs 0 and 1 with equal probability 0.5.

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Amazon questions

Collected from public candidate posts and coding forums. Updated Nov 2026.