Equal Distribution

Subhashis and Bipro participated in many onsite programming contests during their varsity life. From…

Click here to read the complete problem statement.


If you need help solving this problem, mention your approach and ask specific questions. Please avoid sharing your code and asking the Community to figure out “what’s wrong”.

Wrong Answer on testcase 5

// 
// Equal Distribution
// 

#include <bits/stdc++.h>

int main()
{
    long k, s, b;
    scanf("%ld %ld %ld", &k, &s, &b);

    if ((s+b) % k == 0)
        printf("YES\n");
    else
        printf("NO\n");
    return 0;
}