Problem:
 Score : 500 points    Problem Statement There is an apple tree that bears apples of N colors. The N colors of these apples are numbered 1 to N , and there are a_i apples of Color i .  You and Lunlun the dachshund alternately perform the following operation (starting from you):   Choose one or more apples from the tree and eat them. Here, the apples chosen at the same time must all have different colors.   The one who eats the last apple from the tree will be declared winner. If both you and Lunlun play optimally, which will win?      Constraints  1 \leq N \leq 10^5  1 \leq a_i \leq 10^9  All values in input are integers.         Input Input is given from Standard Input in the following format:  N  a_1  a_2  :  a_N       Output If you will win, print first ; if Lunlun will win, print second .        Sample Input 1 2
1
2      Sample Output 1 first  Let Color 1 be red, and Color 2 be blue. In this case, the tree bears one red apple and two blue apples.  You should eat the red apple in your first turn. Lunlun is then forced to eat one of the blue apples, and you can win by eating the other in your next turn.  Note that you are also allowed to eat two apples in your first turn, one red and one blue (not a winning move, though).       Sample Input 2 3
100000
30000
20000      Sample Output 2 second

Solution (Python):
def main():
    n = int(input())
    A = [int(input()) for _ in range(n)]
    if all([a % 2 == 0 for a in A]):
        print('second')
    else:
        print('first')

if __name__ == '__main__':
    main()

Solution (Python):


import sys
from typing import Any, Callable, Deque, Dict, List, Mapping, Optional, Sequence, Set, Tuple, TypeVar, Union






























def main():
    mod = 1000000007                
    inf = float('inf')              
    
    sys.setrecursionlimit(10**6)    
    def input(): return sys.stdin.readline().rstrip()
    def ii():    return int(input())
    def isp():   return input().split()
    def mi():    return map(int, input().split())
    def mi_0():  return map(lambda x: int(x)-1, input().split())
    def lmi():   return list(map(int, input().split()))
    def lmi_0(): return list(map(lambda x: int(x)-1, input().split()))
    def li():    return list(input())
    
    
    n = ii()
    L = [ii() for _ in range(n)]
    print('first') if any(map(lambda x: x%2 == 1, L)) else print('second')


if __name__ == "__main__":
    main()

Solution (Python):
n = int(input())

for i in range(n):
    a = int(input())
    if a %2 != 0:
        print('first')
        exit()
        
print('second')

Solution (Python):
def main():
    N = int(input())
    A = [int(input()) for _ in range(N)]
    flag = True
    for a in A:
        if a % 2 == 1:
            flag = False
            break
            
    if flag:
        print('second')
    else:
        print('first')


if __name__ == "__main__":
    main()

Solution (Python):
N, *A = map(int, open(0).read().split())
print("first") if any(a % 2 for a in A) else print("second")

Solution (Python):



def main():
    N = int(input())
    l = [int(input()) for _ in range(N)]

    if sum(l)%2==1:
        print('first')
    else:
        ret = 'second'
        for i in l:
            if i%2!=0:
                ret = 'first'
                break
        print(ret)

if __name__ == '__main__':
    main()

Solution (Python):
import sys
readline = sys.stdin.readline
sys.setrecursionlimit(10**8)
mod = 10**9+7

INF = 10**18
eps = 10**-7

N = int(readline())
A = [int(readline()) for i in range(N)]

for a in A:
    if a%2:
        print('first')
        exit()
print('second')

Solution (Python):


n = int(input())
odd = even = 0
for _ in range(n):
    apple = int(input())
    if apple % 2 == 0:
        even += 1
    else:
        odd += 1

if odd:
    print('first')
else:
    print('second')

Solution (Python):
n = int(input())
a = [int(input()) for i in range(n)]
f = True
for i in a:
    if i%2==1:
        f = False
if f:
    print('second')
else:
    print('first')

Solution (Python):
n = int(input())
f=True
for i in range(n):
  s = int(input())
  if s%2==1:
    f = False 
if not f:
  print("first")
else:
  print("second")

Solution (Python):
n=int(input())
for i in range(n):
  if int(input())%2==1:
    print('first')
    exit()
print('second')

Solution (Python):






import sys
input = sys.stdin.readline

import math

import bisect
import heapq
from collections import defaultdict
from collections import deque
from collections import Counter
from functools import lru_cache






MOD = 10**9+7
INF = float('inf')
AtoZ = "abcdefghijklmnopqrstuvwxyz"






def I(): return int(input().strip())
def S(): return input().strip()
def IL(): return list(map(int,input().split()))
def SL(): return list(map(str,input().split()))
def ILs(n): return list(int(input()) for _ in range(n))
def SLs(n): return list(input().strip() for _ in range(n))
def ILL(n): return [list(map(int, input().split())) for _ in range(n)]
def SLL(n): return [list(map(str, input().split())) for _ in range(n)]


def P(arg): print(arg); return
def Y(): print("Yes"); return
def N(): print("No"); return
def E(): exit()
def PE(arg): print(arg); exit()
def YE(): print("Yes"); exit()
def NE(): print("No"); exit()


def DD(arg): return defaultdict(arg)



def inv(n): return pow(n, MOD-2, MOD)


kaijo_memo = []
def kaijo(n):
  if(len(kaijo_memo) > n):
    return kaijo_memo[n]
  if(len(kaijo_memo) == 0):
    kaijo_memo.append(1)
  while(len(kaijo_memo) <= n):
    kaijo_memo.append(kaijo_memo[-1] * len(kaijo_memo) % MOD)
  return kaijo_memo[n]

gyaku_kaijo_memo = []
def gyaku_kaijo(n):
  if(len(gyaku_kaijo_memo) > n):
    return gyaku_kaijo_memo[n]
  if(len(gyaku_kaijo_memo) == 0):
    gyaku_kaijo_memo.append(1)
  while(len(gyaku_kaijo_memo) <= n):
    gyaku_kaijo_memo.append(gyaku_kaijo_memo[-1] * pow(len(gyaku_kaijo_memo),MOD-2,MOD) % MOD)
  return gyaku_kaijo_memo[n]

def nCr(n,r):
  if(n == r):
    return 1
  if(n < r or r < 0):
    return 0
  ret = 1
  ret = ret * kaijo(n) % MOD
  ret = ret * gyaku_kaijo(r) % MOD
  ret = ret * gyaku_kaijo(n-r) % MOD
  return ret


def factorization(n):
  arr = []
  temp = n
  for i in range(2, int(-(-n**0.5//1))+1):
    if temp%i==0:
      cnt=0
      while temp%i==0: 
        cnt+=1 
        temp //= i
      arr.append([i, cnt])
  if temp!=1:
    arr.append([temp, 1])
  if arr==[]:
    arr.append([n, 1])
  return arr


def make_divisors(n):
  divisors = []
  for i in range(1, int(n**0.5)+1):
    if n % i == 0:
      divisors.append(i)
      if i != n // i: 
        divisors.append(n//i)
  divisors.sort()
  return divisors


def make_primes(N):
  max = int(math.sqrt(N))
  seachList = [i for i in range(2,N+1)]
  primeNum = []
  while seachList[0] <= max:
    primeNum.append(seachList[0])
    tmp = seachList[0]
    seachList = [i for i in seachList if i % tmp != 0]
  primeNum.extend(seachList)
  return primeNum


def gcd(a, b):
    while b:
        a, b = b, a % b
    return a


def lcm(a, b):
    return a * b // gcd (a, b)


def count_bit(n):
  count = 0
  while n:
    n &= n -1
    count += 1
  return count


def base_10_to_n(X, n):
  if X//n:
    return base_10_to_n(X//n, n)+[X%n]
  return [X%n]

def base_n_to_10(X, n):
  return sum(int(str(X)[-i-1])*n**i for i in range(len(str(X))))


def int_log(n, a):
  count = 0
  while n>=a:
    n //= a
    count += 1
  return count




N = I()
A = ILs(N)

for a in  A:
  if a%2:
    print("first")
    exit()
else:
  print("second")

Solution (Python):





import math
import fractions
import sys
import bisect
import heapq  
import collections
from collections import Counter
from collections import deque
import pprint

sr = lambda: input()
ir = lambda: int(sr())
lr = lambda: list(map(int, sr().split()))

"""nを素因数分解"""
"""2以上の整数n => [[素因数, 指数], ...]の2次元リスト"""
def factorization(n):
    arr = []
    temp = n
    if n == 1:
        return arr

    for i in range(2, int(-(-n**0.5//1))+1):
        if temp%i==0:
            cnt=0
            while temp%i==0:
                cnt+=1
                temp //= i
            arr.append([i, cnt])

    if temp!=1:
        arr.append([temp, 1])

    if arr==[]:
        arr.append([n, 1])

    return arr


def power(a,n,mod):
    x = 1
    while n:
        if n & 1:
            x *= a % mod
        n >>= 1
        a *= a % mod
    return x % mod


def kaijo(n, l, mod):
    if n == 0:
        return 1
    a = n
    tmp = n-1
    while(tmp >= l):
        a = a*tmp%mod
        tmp -= 1
    return a

inf = 10**18
mod = 10**9+7

n = ir()
a = [ir() for i in range(n)]
odd = 0
for num in a:
    if num%2 == 1:
        odd+=1
if odd == 0:
    print('second')
else:
    print('first')

Solution (Python):
N = int(input())
A = [int(input()) for _ in range(N)]

print('second' if all(A[i] % 2 == 0 for i in range(N)) else 'first')

Solution (Python):
n = int(input())
ok = True;
for i in range(n):
  a = int(input())
  if a%2==1:
    ok = False
if ok:
  print("second")
else:
  print("first")

Solution (Python):
n = int(input())
a = [int(input()) for _ in range(n)]
print('second' if all(a[i] % 2 == 0 for i in range(n)) else 'first')

Solution (Python):
import sys
input = sys.stdin.readline

"""
def dfs(x, y):
    if x==0 and y==0:
        return False
        
    res = False
    
    if x>0:
        res |= not dfs(x-1, y)
    
    if y>0:
        res |= not dfs(x, y-1)
    
    if min(x, y)>0:
        res |= not dfs(x-1, y-1)
    
    return res
    
t = [[False]*5 for _ in range(5)]

for i in range(5):
    for j in range(5):
        t[i][j] = dfs(i, j)

for ti in t:
    print(*ti)
"""

N = int(input())
a = [int(input()) for _ in range(N)]

for ai in a:
    if ai%2==1:
        print('first')
        exit()

print('second')

Solution (Python):
N = int(input())
even = 0
A = []

for i in range(N):
    a = int(input())
    if not a%2:
        even += 1
    A.append(a)

if N == 1:
    print("sfeicrosntd"[(A[0]%2)::2])
elif sum(A) == N:
    print("first")
else:
    if even == N:
        print("second")
    else:
        print("first")

Solution (Python):
n = int(input())
for _ in range(n):
    if int(input()) % 2 == 1:
        print("first")
        break
else:
    print("second")

Solution (Python):
n = int(input())
arr = [int(input()) for _ in range(n)]
print("second"if all(arr[i] % 2 == 0 for i in range(n)) else "first")

Solution (Python):
n = int(input())
a = [int(input()) for i in range(n)]
print('second' if all(a[i]%2==0 for i in range(n))else 'first')

Solution (Python):
n=int(input())
for i in range(n):
  if int(input())%2==1:
    print('first')
    quit()
print('second')

Solution (Python):
def getN():
    return int(input())


def getNM():
    return map(int, input().split())


def getList():
    return list(map(int, input().split()))


from collections import defaultdict, deque, Counter
from sys import exit
import math
import copy
from bisect import bisect_left, bisect_right
from heapq import *
import sys


INF = 10 ** 17
MOD = 1000000007

from fractions import *


def inverse(f):
    
    return 1 / f


def combmod(n, k, mod=MOD):
    ret = 1
    for i in range(n - k + 1, n + 1):
        ret *= i
        ret %= mod

    for i in range(1, k + 1):
        ret *= pow(i, mod - 2, mod)
        ret %= mod

    return ret

MOD = 10 ** 9 + 7

def yaku(n):
    res = []
    for i in range(2, int(math.sqrt(n)) + 2):
        tmp = 0
        while(True):
            if n % i == 0:
                tmp += 1
                n //= i
            else:
                break
        if tmp != 0:
            res.append((tmp, i))
    if n != 1:
        res.append((1, n))
    return res

def solve():
    n = getN()
    lis = []
    for i in range(n):
        lis.append(getN())

    lis.sort()
    prev = 0
    res = []
    for idx, num in enumerate(lis):
        if (num - prev) % 2 == 1:
            res.append(idx + 1)
        prev = num
    ans = 0
    for re in res:
        ans = ans ^ re

    if ans != 0:
        print("first")
    else:
        print("second")
    
    return
def main():
    n = getN()
    for _ in range(n):
        solve()


if __name__ == "__main__":
    solve()

Solution (Python):
n=int(input())
a=[]
x=0
for i in range(n):
    x|=int(input())%2

if x==1:
    print('first')
else:
    print('second')

Solution (Python):
def getN():
    return int(input())
def getNM():
    return map(int, input().split())
def getList():
    return list(map(int, input().split()))
def getArray(intn):
    return [int(input()) for i in range(intn)]
def input():
    return sys.stdin.readline().rstrip()
def rand_N(ran1, ran2):
    return random.randint(ran1, ran2)
def rand_List(ran1, ran2, rantime):
    return [random.randint(ran1, ran2) for i in range(rantime)]
def rand_ints_nodup(ran1, ran2, rantime):
  ns = []
  while len(ns) < rantime:
    n = random.randint(ran1, ran2)
    if not n in ns:
      ns.append(n)
  return sorted(ns)

def rand_query(ran1, ran2, rantime):
  r_query = []
  while len(r_query) < rantime:
    n_q = rand_ints_nodup(ran1, ran2, 2)
    if not n_q in r_query:
      r_query.append(n_q)
  return sorted(r_query)

from collections import defaultdict, deque, Counter
from sys import exit
from decimal import *
import heapq
import math
from fractions import gcd
import random
import string
import copy
from itertools import permutations
from operator import mul
from functools import reduce
from bisect import bisect_left, bisect_right

import sys
sys.setrecursionlimit(1000000000)
mod = 10 ** 9 + 7






N = getN()
A = getArray(N)

for i in A:
    if i % 2 != 0:
        print('first')
        exit()
print('second')

Solution (Python):
ans = "second"
n = int(input())
for _ in range(n):
    a = int(input())
    if a%2 == 1:
        ans = "first"
        break
print(ans)

Solution (Python):
n = int(input())
dat = []
oddcnt = 0
for _ in range(n):
    x = int(input())
    dat.append(x)
    if x % 2 == 1:
        oddcnt += 1
if oddcnt == 0:
    print("second")
else:
    print("first")

Solution (Python):
import sys

sys.setrecursionlimit(10 ** 7)
input = sys.stdin.readline
f_inf = float('inf')
mod = 10 ** 9 + 7


def resolve():
    n = int(input())
    A = list(int(input()) for _ in range(n))

    for a in A:
        if a % 2 != 0:
            print("first")
            break
    else:
        print("second")


if __name__ == '__main__':
    resolve()

Solution (Python):
N=int(input())
odd=False
for i in range(N):
    a=int(input())
    if a%2==1:
        odd=True

if odd:
    print("first")
else:
    print("second")

Solution (Python):
N = int(input())
A = [int(input()) for _ in range(N)]
cnt = 0
for i in range(N):
    if A[i]%2==1:
        cnt += 1
if cnt>0:
    print("first")
else:
    print("second")

Solution (Python):
import sys
input = sys.stdin.readline
from collections import *

def dfs(x, y):
    if x==0 and y==0:
        t[x][y] = False
        return False
    
    if x>=1:
        t[x][y] |= not dfs(x-1, y)
        
    if y>=1:
        t[x][y] |= not dfs(x, y-1)
        
    if min(x, y)>=1:
        t[x][y] |= not dfs(x-1, y-1)
   
    return t[x][y]
    
t = [[False]*7 for _ in range(7)]

for i in range(7):
    for j in range(7):
        dfs(i, j)

"""
for ti in t:
    print(*ti)
"""

N = int(input())
flag = True

for _ in range(N):
    a = int(input())
    
    if a%2==1:
        flag = False
        
if flag:
    print('second')
else:
    print('first')

Solution (Python):
import sys
from collections import deque

def solve():
    input = sys.stdin.readline
    N = int(input())
    first = False
    for _ in range(N):
        a = int(input())
        if a % 2 == 1: first = True
    if first: print("first")
    else: print("second")
    
            
    return 0

if __name__ == "__main__":
    solve()

Solution (Python):
n = int(input())
a = []
ans = 'second'
for i in range(n):
    ai = int(input())
    a.append(ai)
    if ai % 2 == 1:
        ans = 'first'
print(ans)

Solution (Python):
n=int(input())
a=[int(input())%2 for _ in range(n)]
if 1 in a:print("first")
else:print("second")

Solution (Python):
n=int(input())
a=[int(input()) for i in range(n)]

print( "second" if all(a[i]%2==0 for i in range(n)) else "first" )

Solution (Python):
n=int(input())
cnt=0
for i in range(n):
    a=int(input())
    cnt+=(a%2)
if cnt==0:
    print("second")    
else:
    print("first")

Solution (Python):
N = int(input())
As = [int(input()) for _ in range(N)]

if all([a%2==0 for a in As]):
    print('second')
else:
    print('first')

Solution (Python):
N = int(input())

for i in range(N):
  temp = int(input())
  if temp%2 == 0:
    continue
  else:
    print("first")
    exit()
print("second")

Solution (Python):
n = int(input())
a = [0] * n
flag = True
for i in range(n):
    a[i] = int(input())
    if a[i] % 2 == 1:
        flag = False
print("second" if flag else "first")

Solution (Python):
n = int(input())
a = []
for _ in range(n):
    a.append(int(input()))
for i in a:
    if i%2==1:
        print('first')
        break
else:
    print('second')

Solution (Python):
N = int(input())
for i in range(N):
    if int(input())%2 != 0:
        print("first")
        exit()
print('second')

Solution (Python):
n = int(input())
a = [int(input()) for _ in range(n)]

for i in range(n):
    if a[i] % 2 == 1:
        print("first")
        exit()

print("second")

Solution (Python):
N=int(input())
a=[0]*N

ans=True
for i in range(N):
    a[i]=int(input())
    if a[i]%2==1:
      ans = False
      
if ans:
   print("second")
else:
  print("first")

Solution (Python):
n=int(input())

c=0
for i in range(n):
  ai=int(input())
  if ai%2!=0:
    c+=1
    break

if c==0:
  print("second")
else:
  print("first")

Solution (Python):
n = int(input())
for _ in range(n):
    a = int(input())
    if a % 2 == 0:
        continue
    print('first')
    break
else:
    print('second')

Solution (Python):
import sys

def IS(): return sys.stdin.readline().rstrip()
def II(): return int(IS())
def MII(): return list(map(int, IS().split()))
def MIIZ(): return list(map(lambda x: x-1, MII()))

def main():
    n = II()
    aa = [II() for _ in range(n)]
    for a in aa:
        if a%2==1:
            print('first')
            return None
    print('second')
if __name__ == '__main__':
    main()

Solution (Python):
n = int(input())

a = []

for i in range(n):
    a.append(int(input()))

print('second' if all(a[i] % 2 == 0 for i in range(n)) else 'first')

Solution (Python):
def solve():
    N = int(input())
    for _ in range(N):
        if int(input()) % 2 != 0:
            print("first")
            return
    else:
        print("second")
    
if __name__ == '__main__':
    solve()

Solution (Python):
n = int(input())
a = [int(input()) for i in range(n)]
print("second" if all(i % 2 == 0 for i in a) else "first")

Solution (Python):
n = int(input())
al = [0] * n
for i in range(n):
    a = int(input())
    if a % 2 != 0:
        print('first')
        break
else:
    print('second')

Solution (Python):
def caddi18_d():
    N = int(input())
    A = [int(input()) for _ in range(N)]

    ans = 'second'
    for a in A:
        if a % 2 == 1:
            ans = 'first'
            break
    print(ans)

caddi18_d()

Solution (Python):
n = int(input())
a = [int(input()) for _ in range(n)]







flag = all(a[i] % 2 == 0 for i in range(n))
if flag:
    print("second")
else:
    print("first")

Solution (Python):
def Z(): return int(input())
def ZZ(): return [int(_) for _ in input().split()]

def main():
  N = Z()
  A = [Z() for _ in range(N)]
  print('first' if any([a%2 == 1 for a in A]) else 'second')
  return

if __name__ == '__main__':
  main()

Solution (Python):
n = int(input())
a_list = [int(input()) for _ in range(n)]

is_odd = [x%2==0 for x in a_list]

if all(is_odd):
    print('second')
else:
    print('first')

Solution (Python):
n = int(input())
for i in range(n):
    a = int(input())
    if a % 2 == 1:
        print("first")
        exit()
print("second")

Solution (Python):
import sys


import math
import collections

import bisect
import itertools
import fractions

import copy
import heapq
import decimal

import queue

sys.setrecursionlimit(10000001)
INF = 10 ** 16
MOD = 10 ** 9 + 7

ni = lambda: int(sys.stdin.readline())
ns = lambda: map(int, sys.stdin.readline().split())
na = lambda: list(map(int, sys.stdin.readline().split()))





def main():
    n = ni()

    a = []

    ans = 0
    flg = True
    for _ in range(n):
        tmp = ni()
        if tmp % 2:
            flg = False
    
    print("second" if flg else "first")


if __name__ == '__main__':
    main()

Solution (Python):
n = int(input())
a = [int(input()) for i in range(n)]
print("second" if all(i % 2 == 0 for i in a) else "first")

Solution (Python):
N = int(input())
A = [int(input()) for _ in range(N)]

cnt = 0
for a in A:
    if a % 2 == 1:
        print('first')
        exit()
        
print('second')

Solution (Python):
print("first" if any(int(input()) & 1 for _ in range(int(input()))) else "second")

Solution (Python):
n=int(input())
A=[int(input()) for _ in range(n)]
H=[a for a in A if a%2==0]
if len(H)==n:
  print("second")
else:
  print("first")

Solution (Python):


n=int(input())
a=[int(input())%2 for _ in range(n)]

if 1 in a:
    print("first")
else:
    print("second")

Solution (Python):
_, *a = open(0)
print(["second","first"][any(int(b)%2 for b in a)])

Solution (Python):
import sys
sys.setrecursionlimit(10 ** 7)
input = sys.stdin.readline

n = int(input())
a = list(int(input()) for i in range(n))

cnt = 0
for i in range(n):
    if a[i]%2==1:cnt+=1

if cnt>0:
    print('first')
else:
    print('second')

Solution (Python):
import sys

sys.setrecursionlimit(10 ** 7)
rl = sys.stdin.readline


def solve():
    N = int(rl())
    a = [int(rl()) for _ in range(N)]
    
    print('second' if all(ai % 2 == 0 for ai in a) else 'first')


if __name__ == '__main__':
    solve()

Solution (Python):
import sys
def input(): return sys.stdin.readline().rstrip()
def main():
    n=int(input())
    A=[int(input())for _ in range(n)]
    print("second" if all(a%2==0 for a in A) else "first")

if __name__=='__main__':
    main()

Solution (Python):
import sys
def input(): return sys.stdin.readline().rstrip()
def main():
    n=int(input())
    A=[int(input())for _ in range(n)]
    print("second" if all(a%2==0 for a in A) else "first")

if __name__=='__main__':
    main()

Solution (Python):
N = int(input())
flag = True
for _ in range(N):
    flag &= (int(input()) % 2 == 0)

print('second' if flag else 'first')

Solution (Python):
n=int(input())
a=[int(input())for _ in range(n)]
f=1
for i in range(n):
	if a[i]%2==1:
		f=0
		break
print("second" if f else "first")

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N = INT()
a = [INT() for _ in range(N)]
print("second" if all(x%2==0 for x in a) else "first")

Solution (Python):
n = int(input())
flag = True
for _ in range(n):
    i = int(input())
    if i%2 == 1:
        print('first')
        exit()
print('second')

Solution (Python):
N=int(input())
 
flag=False
for _ in range(N):
    a=int(input())
    if a%2==1:
        flag=True
if flag:
    print('first')
else:
    print('second')

Solution (Python):
N = int(input())
A = [int(input()) for _ in range(N)]
if len([0 for a in A if a % 2 == 0]) == N:
  print('second')
else:
  print('first')

Solution (Python):
n = int(input())
ai = [int(input()) for i in range(n)]

for i in range(n):
    if ai[i] % 2 != 0:
        print('first')
        exit()
        
print('second')

Solution (Python):

N = int(input())
A = [int(input()) for _ in range(N)]

for a in A:
    if a % 2:
        print('first')
        exit()

print('second')

Solution (Python):
def main():
  n=int(input())
  for _ in range(n):
    if int(input())%2==1:
      print("first")
      return
  print("second")
main()

Solution (Python):
n=int(input())
a=[int(input()) for i in range(n)]

if all([i%2==0 for i in a]):
    print("second")
else:
    print("first")

Solution (Python):
N = int(input())
a = [int(input()) for _ in range(N)]

print("second" if all(a[i] % 2 == 0 for i in range(N)) else "first")

Solution (Python):
n = int(input())
num = []
for i in range(n):
  num.append(int(input()))
ans = "second"  
for n in num:
  if n % 2 == 1:
    ans = "first"
    
print(ans)

Solution (Python):
printn = lambda x: print(x,end='')
inn = lambda : int(input())
inl   = lambda: list(map(int, input().split()))
inm   = lambda:      map(int, input().split())
ins = lambda : input().strip()
DBG = True 
BIG = 10**18
R = 10**9 + 7

def ddprint(x):
  if DBG:
    print(x)

n = inn()
for i in range(n):
    a = inn()
    if a%2==1:
        print("first")
        exit()
print("second")

Solution (Python):
print(["first","second"][all([int(input()) % 2 == 0 for _ in range(int(input()))])])

Solution (Python):
N = int(input())
print("first" if sum([int(input()) % 2 for _ in range(N)]) > 0 else "second")

Solution (Python):
def main():
    N, *A = map(int, open(0).read().split())
    ans = 'second'
    for a in A:
        if a % 2 == 1:
            ans = 'first'
    print(ans)

if __name__ == '__main__':
    main()

Solution (Python):
N=int(input())





ok=False
for i in range(N):
    a=int(input())
    if a%2==1:
        ok=True
if ok:
    print("first")
else:
    print("second")

Solution (Python):
N = int(input())
a = [int(input()) for i in range(N)]
print('second' if all(ai % 2 == 0 for ai in a) else 'first')

Solution (Python):
N = int(input())
A = [int(input()) for _ in range(N)]

odd_flag = False
for a in A:
    if a % 2 == 1:
        odd_flag = True
        break

if odd_flag:
    print("first")
else:
    print("second")

Solution (Python):
import sys
import math  
import bisect  
import queue  


def input():
    return sys.stdin.readline().rstrip()


def main():
    N = int(input())
    A = []
    for _ in range(N):
        a = int(input())
        A.append(a)

    print("second" if all(A[i] % 2 == 0 for i in range(N)) else "first")


if __name__ == '__main__':
    main()

Solution (Python):
import sys
sys.setrecursionlimit(10 ** 5 + 10)
def input(): return sys.stdin.readline().strip()

def resolve():
    N=int(input())
    A=[int(input()) for i in range(N)]

    if all(i%2==0 for i in A):
        print('second')
    else:
        print('first')




resolve()

Solution (Python):
import sys

n = int(input())
a = []
for _ in range(n):
    a.append(int(input()))
    
for i in a:
    if i % 2 == 0:
        continue
    else:
        print("first")
        sys.exit()
        
print("second")

Solution (Python):
import sys
readline = sys.stdin.buffer.readline
def even(n): return 1 if n%2==0 else 0

n = int(readline())
lst1 = []
for i in range(n):
    lst1.append(int(readline()))

print("second" if all(i%2==0 for i in lst1) else "first")

Solution (Python):
import sys
sr = lambda: sys.stdin.readline().rstrip()
ir = lambda: int(sr())
lr = lambda: list(map(int, sr().split()))

N = ir()
ans = "second"
for n in range(N):
    if ir() % 2 == 1:
        ans = "first"
print(ans)

Solution (Python):
n = int(input())
for i in range(n):
  i = int(input())
  if i%2 == 1:
    print('first')
    exit()
print('second')

Solution (Python):
n = int(input())
A = [int(input()) for i in range(n)]

print('second' if all(A[i] % 2 == 0 for i in range(n)) else 'first')

Solution (Python):
_,*a=open(0);print('first' if any(int(x)%2 for x in a)else'second')

Solution (Python):
import collections
N = int(input())
a = [0] * N
for i in range(N):
    a[i] = int(input())
def solve():
    return any(x % 2 == 1 for x in a)
print('first' if solve() else 'second')

Solution (Python):
N,*L = map(int, open(0).read().split())
if all(c%2==0 for c in L):
  print('second')
else:
  print('first')

Solution (Python):
N=int(input())
A=[]
flag=False
for i in range(N):
    A.append(int(input()))
    if A[i]%2==1:
        flag=True

if not flag:
    print("second")
else:
    print("first")

Solution (Python):











N=int(input())
A=[0] * N
for i in range(N):
  A[i] = int(input())
  
A = sorted(A)
minus = 0
m = []
for i in range(len(A)):
  if (A[i] - minus)%2 == 1:
    m += [N-i]
  minus = A[i] + minus

if len(m) == 0:
  print("second")
else:
  from functools import reduce
  r = reduce(lambda x,y:x^y,m)
  print(("first","second")[r == 0])

Solution (Python):
from sys import stdin, stdout
import bisect

n = int(stdin.readline().strip())
flag = 0
for i in range(n):
    tmp = int(stdin.readline().strip())
    if tmp % 2:
        flag = 1
        break
if flag:
    stdout.writelines('first\n')
else:
    stdout.writelines('second\n')

Solution (Python):
n=int(input())
A=[int(input()) for _ in range(n)]

if all([a%2==0 for a in A]):
    print('second')
else:
    print('first')

Solution (Python):
N = int(input())
l = [int(input()) for _ in range(N)]
print("second" if all(map(lambda x:x%2==0, l)) else "first")

Solution (Python):
import sys

n, *a = map(int, sys.stdin.read().split())
print('second' if all(x % 2 == 0 for x in a) else 'first')

Solution (Python):

n = int(input())
a = [int(input()) for _ in range(n)]
print('second' if all(a[i] % 2 == 0 for i in range(n)) else 'first')

Solution (Python):
import sys
def input(): return sys.stdin.readline().strip()
def main():
    N = int(input())
    A = [int(input()) for _ in range(N)]
    print("first") if any([a%2 for a in A]) else print("second")
if __name__ == "__main__":
    main()

Solution (Python):
import sys
def input(): return sys.stdin.readline().strip()
def main():
    N = int(input())
    A = [int(input()) for _ in range(N)]
    print("second") if all(( a%2==0 for a in A)) else print("first")
if __name__ == "__main__":
    main()

Solution (Python):
import sys
def input(): return sys.stdin.readline().strip()
def main():
    N = int(input())
    A = (int(input()) for _ in range(N))
    print("second") if all(( a%2==0 for a in A)) else print("first")
if __name__ == "__main__":
    main()

Solution (Python):
import numpy as np
 
def main():
    stdin = np.fromstring(open(0).read(), dtype=np.int64, sep=' ')
    A = stdin[1:]
    A = np.mod(A, 2)
    print("first") if np.count_nonzero(A) else print("second")
if __name__ == "__main__":
    main()

Solution (Python):
import numpy as np

def main():
    stdin = np.fromstring(open(0).read(), dtype=np.int32, sep=' ')
    N = stdin[0]
    A = stdin[1:]
    A = np.mod(A, 2)
    print("first") if np.count_nonzero(A) else print("second")
if __name__ == "__main__":
    main()

Solution (Python):
n = int(input())
flag = True
for _ in range(n):
    ai = int(input())
    if ai % 2 == 0:
        continue
    else:
        flag = False
if flag:
    print("second")
else:
    print("first")

Solution (Python):
import sys
def input():
    return sys.stdin.readline()[:-1]
N=int(input())
a=[int(input())for i in range(N)]
for i in a:
    if i%2:
        print("first")
        break
else:
    print("second")

Solution (Python):
n = int(input())
al = []
for _ in range(n):
    a = int(input())
    al.append(a)

if all(a % 2 == 0for a in al):
    print("second")
else:
    print("first")

Solution (Python):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

n = int(readline())
print('second' if all(int(readline()) % 2 == 0 for i in range(n)) else 'first')