A perfect number is a positive integer that is equal to the sum of its proper positive divisors, that is, the sum of its positive divisors excluding the number itself.
27 factors are 1,3,9,27
but 27 is not equal to 1+3+9, so 27 is not a perfect number.
factors of 28 = 1,2,14,7,4,28
1+2+4+7+14 = 28
So, 28 is perfect number.