题意:中文。。。你们懂得。

析:这个就是一个水题博弈,就是一个巴什博弈定理,直接就没有变,如果你们看过我写的那个,这个题绝对水过。

附地址:http://www.cnblogs.com/dwtfukgv/p/5517818.html

看完后就懂了吧,不用说了,直接上代码就OK。

代码如下:

#include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <cstdio>

using namespace std;

int main(){
    int n, m, T;  cin >> T;
    while(T--){
        scanf("%d %d", &n, &m);
        if(n % (m+1) != 0)  puts("first");
        else  puts("second");
    }
    return 0;
}

 

 

http://www.cnblogs.com/dwtfukgv/p/5517818.html

相关文章:

  • 2021-12-10
  • 2021-07-22
  • 2021-07-04
  • 2021-06-11
  • 2021-12-22
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-06-17
  • 2022-12-23
  • 2022-02-01
  • 2022-01-25
  • 2021-06-13
  • 2021-12-08
  • 2021-08-27
相关资源
相似解决方案