n = 35 (slider from 1 to 50, step 1)
p = 0.46 (slider from 0 to 1, step 0.01)
f(x) = n! / (x! (n - x)!) p^(x) (1 - p)^(n - x)
g(x) = f(floor(x + 0.5))
o = UpperSum(g, -0.5, n + 0.5, n + 1)
a = 12 (slider from 0 to 50, step 1)
b = 19 (slider from 0 to 50, step 1)
w = UpperSum(g, -0.5 + a, b + 0.5, b - a + 1)

Tool: Bin
Input: k, p, n
Output: a

a: n! / (k! (n - k)!) p^(k) (1 - p)^(n - k)