Define the cumulative distribution function of Bernoulli

The cumulative distribution function of a Bernoulli random variable is a function that gives the probability that the random variable is less than or equal to a certain value.

For a Bernoulli random variable X with parameter p (where p is the probability of success), the cumulative distribution function F(x) is given by:

F(x) = P(X ≤ x)

It can be defined as:
F(x) = 0, when x < 0
F(x) = 1 - p, when 0 ≤ x < 1
F(x) = 1, when x ≥ 1