Doubt reagarding playing with divisor is fun

I am calculation power of prime P in that number for that if any prime frequency is a then P^1,P^2 . . . . till P^a will contribute to power of P in number. And for other n-1 number we can select any subset power(2,sum-arr[i]) and power of P is (1+2+3+. . +a)^(2,sum-arr[i]);
Can you explain what is wrong in my code

Hello @anand_54 please share your code by saving it on Ide.codingblocks.com

this is my code for this problem

@anand_54 your logic was partialyy incorrect :

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.