All problems

Estimating Conversions With the Normal Approximation

hardPythonDistributionsNormalBinomial

You're on the growth team at Lumen Ads. A landing page takes a roughly fixed number of clicks on an ordinary day, and each click has some chance of turning into a signup, independently of the others. Finance has been told to plan for "more than 25 signups on a good day" and wants to know how often a day like that actually turns up, so the forecast can be labelled honestly rather than optimistically. Other pages get the same question with their own traffic, their own conversion rate and their own headline number.

The exact answer means adding up hundreds of terms, so the team's house convention for counts this large is to approximate the signup count with a normal distribution having the same mean and the same standard deviation as the true count, and to apply the usual half-unit continuity correction when a whole-number cutoff is moved onto a continuous curve.

Task: Print the approximate probability of more than the stated number of signups in a day - the right-hand tail, using the normal approximation described above with the half-unit correction - rounded to 4 decimals.

Input

Three lines: how many clicks the page takes in a day, the chance a single click converts as a decimal between 0 and 1, and the whole-number signup count the forecast has to beat.

Output

One line holding the probability, rounded to 4 decimals and printed the way Python prints a float - 0.1071.

Example:

Input:
1000
0.02
25

Output:
0.1071

Sign in to solve this problem

Reading problems is free for everyone — solving them (Run, Submit, and tracking what you've solved) needs an account.

Sign in

Discussion

Sign in to join the discussion — reading is open to everyone.

Loading comments…