https://www.codechef.com/problems/ICM2008 - problem

https://www.codechef.com/viewsolution/33535903- my solution

the logic i used: i calculated relative distance using fabs(a-b) and relative speed using fabs(c-d)

the i checked whether distance%relative==0 or not

i also added special case where relative==0 to avoid divide by 0 error

note: for the case 10 20 3 7 , my codeblocks said βNOβ (correct answer)

but online ide said βYESβ ?? i am confused .

thank you for your help guys