#include<bits/stdc++.h>
using namespace std;
int main()
{
	int n,k;
	cin>>n>>k;
	int a[n],i=0;
	for (i = 0; i < n; ++i)
	 {
	 	cin>>a[i];
	 } 
	int dp[k+1]={0};
	dp[0]=-1;
	for(i=0;i<=k;i++)
	{
		if(dp[i]==-1)
		{
			for(int j=0;j<n;j++)
			{
				if(i+a[j]<=k)dp[i+a[j]]=1; 
			}
		}
		else if(dp[i]==0)
		{
			int z=1;
			for(int j=0;j<n;j++)
			{
				if(i-a[j]<0) break;
				if(dp[i-a[j]]==-1){z=0;break;}
			}
			if(z==0)dp[i] = 1;
			else {
				dp[i] = -1;
				for(int j=0;j<n;j++)
				{
					if(i+a[j]<=k)dp[i+a[j]]=1; 
				}
			}
		}
	}
	// for(i=0;i<=k;i++) cout<<dp[i]<<" ";
	if(dp[k]==-1)cout<<"second"<<endl;
	else cout<<"first"<<endl;
	return 0;
}