108. Vector subscript can be used for non-contiguous array sections.#

topic: Arrays

Note

This tip is a draft1.

A vector subscript can be used for non-contiguous array sections, for example

real :: x(5) print*,x([2,4])

An array section with a vector subscript cannot be passed as an intent(out) or intent(in out) argument.



1

From the perspective of FortranTip Browser, “draft” means that it hasn’t been edited for formatting, hasn’t had corresponding Fortran programs added, the text content hasn’t been enhanced, etc. Draft texts are extracted from the corresponding Tweet using the Twitter API.