Write a program to accept two numbers n1 and n2 in the main method. With the of a function

Write a program to accept two numbers n1 and n2 in the main method. With the of a function void amicable(int, int) display the message”amicable” if they are amicable otherwise display the message “not amicable” if they are not amicable.
[Amicable numbers are two nos if each is equal to the sum of the proper divisors of the other nos .]Example — 220 and 284 are amicable numbers.​

Leave a Reply