I was rather surprised to see this result (on Nag f90 on HP-UX and Cray f90
on T3E)
cat temp1.f90
program temp1
integer,allocatable :: a(:,:,:)
allocate (a(0:2,0:2,0:2))
print *, LBOUND(a)
print *, LBOUND(a(:,:,:))
print *, UBOUND(a)
print *, UBOUND(a(:,:,:))
end program temp1
frjb@fr0400: a.out
0 0 0
1 1 1
2 2 2
3 3 3
Why does adding the colon notation change the result?
Jon
--
John Bray, Numerical Weather Prediction Tel: +44 (0) 1344 854035
Room 337 [log in to unmask]
The Met. Office http://www.met-office.gov.uk
London Road, Bracknell, RG12 2SZ, UK http://www.jrbray.org.uk
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|