question link
my solution
please give me a test case where my code fails
You really want to do:
if(b<ans)
{
pos=m;
ans=b;
}
?
i’m sorry pos=i but even after changing that i’m getting wrong answer
You really want to do:
if(b<ans)
{
pos=m;
ans=b;
}
?
i’m sorry pos=i but even after changing that i’m getting wrong answer