| 记录编号 | 349949 | 评测结果 | AAAAAAAAAA | ||
|---|---|---|---|---|---|
| 题目名称 | 2546.取石块儿 | 最终得分 | 100 | ||
| 用户昵称 | 是否通过 | 通过 | |||
| 代码语言 | C++ | 运行时间 | 1.884 s | ||
| 提交时间 | 2016-11-15 14:23:28 | 内存使用 | 0.31 MiB | ||
#include<iostream>
#include<cstdio>
using namespace std;
int main()
{
	int t;
	freopen("tstones.in","r",stdin);
	freopen("tstones.out","w",stdout);
	cin>>t;
	for(int i=0;i<t;i++)
	{
		long long n,k;
		cin>>n>>k;
		if(n%(k+1)==0)cout<<"YES"<<endl;
		//cout<<n%(k+1)<<endl;
		else cout<<"NO"<<endl;
	}
	return 0;
}