Computer Science, asked by MAKTVDTO, 1 year ago

Write a program to aacept a number and check whether it is a perfect number or not.A perfect number is a number if the sum of its divisors , excluding the number is equal to the number itself.
Example:6 as 1+2+3=6
28 as 1+2+4+7+14=28
To exclude the number from the list of divisors, the loop of divisors can be taken upto half of the number . Eg: for 6 it can go upto 5 or upto 3.

Answers

Answered by kumarkshitij552
1
The work is a little untidy pls understand it.
If you have any doubt pls leave a comment.
Hope it helps you.
Attachments:

MAKTVDTO: THANKYOU verry much. Its exactly what i wanted. Thankyou soo much.
kumarkshitij552: No problem
Similar questions