Skip to content
GATEiit

GATE DA · Probability and Statistics

Uniform, Bernoulli and binomial distributions

The discrete uniform, Bernoulli and binomial distributions: when each applies, their PMFs, means, variances and modes, and the standard binomial questions on exactly, at least and at most k successes.

Before you start

This topic comes before: Logistic regression, Uniform, exponential, Poisson, normal, standard normal, t- and chi-squared distributions

Concept notes

1. Discrete uniform distribution

X is discrete uniform on the integers a,a+1,…,b if each of the n=b−a+1 values has probability 1/n. It models a fair die, a random digit, or a randomly chosen index.

E[X]=a+b2,Var(X)=n2−112.

The variance depends only on the number of values, not where they sit, since shifting does not change spread.

Example n Mean Variance
Fair die {1,…,6} 6 3.5 35/12≈2.92
Random digit {0,…,9} 10 4.5 99/12=8.25
{1,…,10} 10 5.5 8.25

For a uniform choice on a non-consecutive set (say {2,4,6}), use the general formulas, or write it as a linear function of a consecutive uniform (X=2U with U uniform on {1,2,3}).

2. Bernoulli distribution

A Bernoulli trial has two outcomes: success (X=1) with probability p and failure (X=0) with probability q=1−p. P(X=x)=px(1−p)1−x, x∈{0,1};E[X]=p,Var(X)=p(1−p).

Since X2=X for a 0/1 variable, E[X2]=p and Var(X)=p−p2.

The variance p(1−p) is largest, 1/4, at p=1/2 and is 0 at p=0 or 1 (no randomness).

Every indicator IA is Bernoulli with p=P(A). A binary label in classification, a click or no click, a defective item: each is a Bernoulli trial. The log-likelihood of Bernoulli data is the cross-entropy loss used in logistic regression.

3. Binomial distribution

X∼Bin(n,p) counts the successes in n independent Bernoulli trials, each with the same success probability p: P(X=k)=(nk)pk(1−p)n−k,k=0,1,…,n. (nk) counts which trials succeed; pkqn−k is the probability of each such pattern.

Writing X=I1+⋯+In (independent Bernoulli) gives E[X]=np,Var(X)=np(1−p)=npq. So Var(X)<E[X] whenever 0<p<1. If the mean and variance are given, q=Var/mean, then p=1−q and n=mean/p.

Checklist (all four must hold): fixed n; two outcomes per trial; independent trials; constant p. Drawing without replacement from a small population breaks independence (that count is hypergeometric).

Sums: if X∼Bin(n,p) and Y∼Bin(m,p) are independent, then X+Y∼Bin(n+m,p). The p must be the same.

0123456789100.267 at k = 3k (number of successes)
PMF of Bin(10, 0.3): mean 3, mode 3, right-skewed because p < 0.5

4. Working with the binomial: at least, at most, mode

At least one: P(X≥1)=1−(1−p)n. To find the smallest n with P(X≥1)≥c, solve (1−p)n≤1−c, so n≥ln⁡(1−c)ln⁡(1−p), then round up.

At most / at least k: add the few terms on the short side, using the complement if needed: P(X≥2)=1−P(0)−P(1).

Ratio of successive terms: P(X=k)P(X=k−1)=n−k+1k⋅pq. This exceeds 1 while k<(n+1)p. So the mode is ⌊(n+1)p⌋; if (n+1)p is an integer, both (n+1)p and (n+1)p−1 are modes.

Shape: symmetric when p=1/2, right-skewed when p<1/2, left-skewed when p>1/2. For large n it is close to a normal with mean np and variance npq; for large n and small p it is close to Poisson with mean np.

Formulas to remember

Discrete uniform on a..bn=b−a+1
E[X]=a+b2,Var(X)=n2−112
Bernoulli
E[X]=p,Var(X)=p(1−p)
Binomial PMF
P(X=k)=(nk)pk(1−p)n−k
Binomial mean and variance
E[X]=np,Var(X)=np(1−p)
At least one success
P(X≥1)=1−(1−p)n
Binomial modeTwo modes if (n+1)p is an integer
⌊(n+1)p⌋
Successive-term ratio
P(k)P(k−1)=n−k+1k⋅p1−p

Common mistakes

  • Using the binomial for draws without replacement from a small population; the trials are not independent.
  • Forgetting the (nk) factor and computing only pkqn−k, the probability of one pattern.
  • Rounding down when solving for the smallest n in an "at least one" question; always round up and check.
  • Giving np as the mode; the mode is an integer, ⌊(n+1)p⌋.
  • Adding binomials with different p and calling the sum binomial.

Worked examples

Try each step yourself, then reveal the working.

Example 1: Guessing in a 10-question test

numerical

A student guesses every one of 10 four-option MCQs. Find the probability of exactly 3 correct and of at least 1 correct.

  1. Step 1: Identify the distribution.

    Try it on paper first.

Example 2: Recover n and p from the mean and variance

numerical

A binomial random variable has mean 4 and variance 2.4. Find n and p.

  1. Step 1: Divide the variance by the mean.

    Try it on paper first.

Example 3: Mean and variance of a random digit

numerical

A digit X is chosen uniformly from 1,2,…,10. Find E[X] and Var(X), and check the variance directly.

  1. Step 1: Use the uniform formulas.

    Try it on paper first.

Example 4: Binomial or not?

conceptual

Which of these counts are binomial? (i) Heads in 20 tosses of a fair coin. (ii) Red cards when 5 cards are dealt from a deck. (iii) Rolls until the first six. (iv) Defective items in a sample of 50 from a huge lot with 2% defective.

  1. Step 1: Check the four conditions for each.

    Try it on paper first.

Previous year questions

5 official GATE DA questions on this topic, newest first.

Practise these 5 PYQs →

Topic test

10 questions: up to 4 official PYQs and original practice questions, with GATE marking (MCQ wrong answers lose marks). Score 60% or more to pass. A new set is drawn each time.

Mark as mastered

Loading your progress…

My revision notes

Notes written by the GATEiit team against the official GATE DA syllabus; being checked by a reviewer. Updated 2026-11-21. Spotted a mistake? Use Report an issue on any question, or contact us.