OJ-Problems-Source/HDOJ/1846_autoAC.cpp
2016-08-17 15:13:51 +08:00

17 lines
266 B
C++

#include<stdio.h>
int main()
{
int c;
scanf("%d",&c);
while(c--)
{
int n,m;
scanf("%d%d",&n,&m);
if(n%(m+1)==0)
printf("second\n");
else
printf("first\n");
}
return 0;
}