module arguments_module ! .. Implicit None Statement .. implicit none contains subroutine print_diagonal(x) ! x is an "dummy argument" - reference to ! the memory location of a ! .. Array Arguments .. integer, dimension (:,:) :: x ! .. Local Scalars .. integer :: i ! .. Local Arrays .. integer, dimension (SIZE(x,dim=1)) :: d ! d is an "automatic array" ! .. Intrinsic Functions .. intrinsic SIZE ! .. Executable Statements .. do i = 1, SIZE(x,dim=1) d(i) = x(i,i) end do print *, d end subroutine print_diagonal end module arguments_module