#include <bits/stdc++.h>
using namespace std;
int minEl, n;
vector<int> dp1, dp2;
bool play2(int k, vector<int> &A);
bool play1(int k, vector<int> &A) {
  if (k < minEl) return 0;
  if (dp1[k] != -1) return dp1[k];
  for (int i = 0; i < A.size(); ++i) {
    bool ans = play2(k - A[i], A);
    if (k - A[i] >= 0 && ans == 1)
      dp1[k] = 0;
    else if (k - A[i] >= 0 && ans == 0) {
      dp1[k] = 1;
      break;
    }
  }
  if (dp1[k] != 0)
    return dp1[k] = 1;
  else
    return 0;
}
bool play2(int k, vector<int> &A) {
  if (k < minEl) return 0;
  if (dp2[k] != -1) return dp2[k];
  for (int i = 0; i < A.size(); ++i) {
    bool ans = play1(k - A[i], A);
    if (k - A[i] >= 0 && ans == 1)
      dp2[k] = 0;
    else if (k - A[i] >= 0 && ans == 0) {
      dp2[k] = 1;
      break;
    }
  }
  if (dp2[k] != 0)
    return 1;
  else
    return 0;
}
int main() {
  int n, k;
  cin >> n >> k;
  vector<int> A(n);
  minEl = INT_MAX;
  for (int i = 0; i < n; ++i) {
    cin >> A[i];
    minEl = min(minEl, A[i]);
  }
  dp1.clear();
  dp2.clear();
  dp1.resize(k + 1, -1);
  dp2.resize(k + 1, -1);
  play1(k, A);
  if (dp1[k] == 1) cout << "first" << endl;
  if (dp1[k] == 0) cout << "second" << endl;
  return 0;
}
