It depends on which statistic test we wish to perform, the formula to find a degree of freedom could be different.
for Normal Distribution test, we do not need to find a degree of freedom
for T-test and Chi-Square test, we do n - 1 to find the degree of freedom, where 'n' is the sample size.
if we have two different sample size, then the degree of freedom is given by (n₁ + n₂) - 2
We are given only one sample size, n = 28, hence the degree of freedom is 28 - 1 = 27