【HDU1846】Brave Game(博弈论)

题面

HDU

题解

\(Bash\ Game\)模板题

#include<iostream>
using namespace std;
int T,n,m;
int main()
{
	ios::sync_with_stdio(false);
	cin>>T;
	while(T--)
	{
		cin>>n>>m;
		if(n%(m+1))cout<<"first"<<endl;
		else cout<<"second"<<endl;
	}
	return 0;
}

posted @ 2018-08-15 19:44  小蒟蒻yyb  阅读(354)  评论(0编辑  收藏  举报