#include <bits/stdc++.h>
using namespace std;
int dp[100001][2];
int a[100], n, min_val = INT_MAX;
int dfs(int k, int level) {
  if (k < min_val) return level;
  if (dp[k][level] != -1) return dp[k][level];
  if (level == 0) {
    int mx = 0;
    for (int i = 0; i < n; i++) {
      if (k >= a[i]) mx = max(mx, dfs(k - a[i], !(level & 1)));
    }
    dp[k][level] = mx;
    return mx;
  }
  if (level == 1) {
    int mn = 1;
    for (int i = 0; i < n; i++) {
      if (k >= a[i]) mn = min(mn, dfs(k - a[i], !(level & 1)));
    }
    dp[k][level] = mn;
    return mn;
  }
}
int main() {
  int k;
  cin >> n >> k;
  for (int i = 0; i < n; i++) {
    cin >> a[i];
    min_val = min(min_val, a[i]);
  }
  int level = 0;
  memset(dp, -1, sizeof(dp));
  int ans = dfs(k, level);
  if (ans)
    cout << "first\n";
  else
    cout << "second\n";
}
