I have an array, from which I want to have some information.
I wrote a small DO-loop, but I don't know why it always returns
integer :: inn=0
parameter :: m=115200
real*8 :: da1(m)
DO i=1, 115200
IF( i<=19200 .and. da1(i)>1 .and. da1(i)<999.9999 .and. da1(i)<-1 )then
inn=inn+1
END IF
END DO
write(*,*) 'inn=',inn
- why it always prints 0, whereas, I checked in the file and this array indeed has many values in the defined range
- If the fault is in logic, could someone please give me some pointers on not making such mistakes in the future?