codechef ATMOQ

why it’s showing wrong answer??

for each i —< pi

calculated element in each connected component…

ans will be their lcm…

solution

Can you provde the link to your question

Refer to this answer to see why your code is wrong

Thnxx got it.but is there any thing wrong other than calculating lcm??