ES 112 Sections 4 & 5 Homework 2 Due: 25/03/2015 Lab Hour A

ES 112
Sections 4 & 5
Homework 2
Due: 25/03/2015 Lab Hour
A perfect number is an integer which is equal to the sum of its divisors except
itself. For example, the divisors of 28 except itself are 1, 2, 4, 7, and 14. The
sum of these divisors is 1+2+4+7+14 = 28. Therefore, 28 is a perfect number.
Write a pseudocode for a program in which the user enters an integer and the
program checks and prints whether that number is perfect or not.
Notes:
 You must submit your homework as a hard (printed) copy at the specified
lecture or lab hour.
 Homework sent using e-mail will be disregarded.
 Late homework submissions will not be accepted.
WARNING: Cheating and/or copying somebody else’s work will NOT be
tolerated and will be officially reported to the Dean's Office.