HDU.1846 Brave Game (博弈论 巴什博弈)

HDU.1846 Brave Game (博弈论 巴什博弈)

题意分析

巴什博奕裸题
博弈论快速入门

代码总览

include <bits/stdc++.h>
using namespace std;
int main()
{
    int t;
    scanf("%d",&t);
    while(t--){
        int n,m;
        scanf("%d %d",&n,&m);
        int r,s;
        r = n%(m+1);
        if(r == 0) printf("second
");
        else printf("first
");
    }
    return 0;
}
原文地址:https://www.cnblogs.com/pengwill/p/7367038.html