Why getting wa?

https://www.codechef.com/viewsolution/34702048

Hi can you describe your approach that you used in the code?

used this condition…

     int k=(r-l)/3;
    if((r-l)%3==0 && k<=m)
    {
        cout<<"No";
    }
    else
    {
        cout<<"Yes";
    }
1 Like