Brave Game HDU - 1846(巴什博奕)

Brave Game

HDU - 1846


裸的巴什博奕:

#include <cstdio>
#include <algorithm>
#include <iostream>
using namespace std;
int main(){
	int C;
	scanf("%d", &C);
	while(C--){
		int n, m;
		scanf("%d%d", &n, &m);
		if(n%(m+1)) printf("first\n");
		else printf("second\n"); 
	}
	return 0;
}

猜你喜欢

转载自blog.csdn.net/sirius_han/article/details/80431823