Variance Practice Problems

Last Updated : 6 Jul, 2026

Variance is a measure of dispersion that indicates how far the values in a dataset are spread out from the mean.

Example 1: Calculate the variance of the sample data: 7, 11, 15, 19, 24.

We have the data, 7, 11, 15, 19, 24

Find mean of the data.

x̄ = (7 + 11 + 15 + 19 + 24)/5
   = 76/5
   = 15.2

Using the formula for variance we get,

s2 = ∑ (xi - x̄)2/(n - 1)
     = (67.24 + 17.64 + 0.04 + 14.44 + 77.44)/(5 - 1)
     = 176.8/4
     = 44.2

Example 2: Calculate the number of observations if the variance of the dataset is 12 and the sum of squared differences of data from the mean is 156.

We have,

(xi - x̄)2 = 156
σ2 = 12

Using the  formula for variance we get,

σ2 = ∑ (xi - x̄)2/n
12 = 156/n
12n = 156
n = 156/ 12
n = 13

Example 3: Calculate the variance for the given data

xi

fi

101
43
65
81

xi

fi

fixi

(xi - x̄) 

(xi - x̄)2

fi(xi - x̄)2

1011041616
4312-2412
6530000
818244

Mean (x̄) = ∑(fi xi)/∑(fi)

              = (10×1 + 4×3 + 6×5 + 8×1)/(1+3+5+1)
              = 60/10 = 6

n = ∑(fi) = 1+3+5+1 = 10

Now,

σ2 = (∑in fi(xi - x̄)2/n)
= (16 + 12 + 0 +4)/10
= 3.2

Variance(σ2) = 3.2

Example 4: Find the variance of the following data table

Class

Frequency

0-103
10-206
20-304
30-402
40-501

Class

 Xi

fi

f×Xi

Xi - μ

(Xi - μ)2

f×(Xi - μ)2

0-10

5

3

15

-15

225

675

10-20

15

6

90

-5

25

150

20-30

25

4

100

5

25

100

30-40

35

2

70

15

225

450

40-50

45

1

45

25

625

625

Total

 

16

320

 

 

2000

Mean (μ) = ∑(fi xi)/∑(fi)
               = 320/16 = 20

σ2 = (∑in fi(xi - μ)2/n)

    = [(2000)/(16)]
    = (125)

The variance of given data set is 125.

Comment

Explore