program caddi2018_b
    use,intrinsic :: iso_fortran_env
    implicit none
    integer(int32):: n,i
    integer(int32):: a
    logical:: all_even = .true.

    read*, n

    do i=1,n
        read*, a
        all_even = all_even .and. (mod(a,2)==0)
    end do

    if (all_even) then
        print'(a)', 'second'
    else
        print'(a)', 'first'
    end if
end program caddi2018_b