Check if a Number is a Perfect Number Write a program to check if a number is perfect (sum of its proper divisors equals the number).