#C6615. Perfect Number Checker
Perfect Number Checker
Perfect Number Checker
Given a positive integer \(n\), determine whether it is a perfect number. A perfect number is defined as a number that is equal to the sum of its proper divisors (i.e., all positive divisors excluding the number itself). In mathematical terms, \(n\) is perfect if
\(\sum_{d|n,\,d<n} d = n\)
For example, 28 is a perfect number because its proper divisors are 1, 2, 4, 7, and 14, and \(1+2+4+7+14 = 28\).
inputFormat
The input consists of a single line containing a positive integer \(n\) (with \(n \geq 1\)). The integer is provided via standard input.
outputFormat
Output a single line to standard output: print "True" if \(n\) is a perfect number, otherwise print "False".
## sample6
True