program test03_2
 implicit none
 integer,allocatable :: a(:)
 integer,allocatable :: b(:)
 integer N
 integer i, j, jj
 integer :: js(1)
 integer :: yesf=0
 integer :: no=0

 read(5,*) N
 allocate(a(N))

 read(5,*) (a(i), i=1,N)


 do j=1,N,2
 allocate(b(j))
 do jj=1,j
  b(jj)=a(jj)
 end do

!print *, minloc(b)
 js=minloc(b)
 if ( j == js(1) ) then
  yesf=yesf+1
 end if

 deallocate(b)
 end do

 write (*,fmt='(i0)',advance='no') yesf

endprogram test03_2
