您的位置:首页 > 其它

[2101]:A + B Problem Too

2015-11-24 18:50 441 查看
A + B Problem Too

Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)

Total Submission(s): 14190 Accepted Submission(s): 10554

Problem Description

This problem is also a A + B problem,but it has a little difference,you should determine does (a+b) could be divided with 86.For example ,if (A+B)=98,you should output no for result.

Input

Each line will contain two integers A and B. Process to end of file.

Output

For each case, if(A+B)%86=0,output yes in one line,else output no in one line.

Sample Input

1 1

8600 8600

Sample Output

no

yes

这道题也是很简单的一道题,它与A+BI的差别在于:这道题多了对%(取余)的理解

#include <stdio.h>

int main()
{
int a, b;
while(scanf("%d%d", &a, &b)!=EOF){
if((a+b)%86){
printf("no\n");
}
else{
printf("yes\n");
}
}
return 0;
}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: