题解 | 【模板】巴什博弈

【模板】巴什博弈

https://www.nowcoder.com/practice/9bb882504d574ec287f69e967ce0fb95?channelPut=tracker3

#include <bits/stdc++.h>
using ll = long long;
using namespace std;
int main()
{
    ll t;
    cin>>t;
    while(t--)
    {
        ll n,m;
        cin>>n>>m;
       if(n%(m+1) ==0 ){
        cout<<"NO"<<endl;
       }
       else cout<<"YES"<<endl;
    }
    return 0;
}

全部评论

相关推荐

评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务