Sir can u help me in figuring out mistake
Hey @spagire4
There is a logical mistake on your end
The question says that ai are co-prime
Not that they are prime
So you can find inverse using pow(a,mod-2,mod)
You need to use mod_inverse formula for it
@Aarnav-Jindal-1059677350830863
Sir i have done as u said but getting segmentation fault can please debug it
code: https://ide.codingblocks.com/s/208975
@spagire4
Line 13 should be this
ll gcd1=gcd_E(b%a,a,x1,y1);
If your doubt is resolved please close it