Skip to main content

  | मौसम…

411 समाचार
Public archive edition · Attributed source reporting with original dates · AI drafts are excluded

411 REFERENCE · Wikibooks

Ada Programming/Attributes/'First

Reference material by Wikibooks contributors. This retains its source identity and is not 411 news reporting.

Attributes 'First __TOC__ Description X'First, where X is any scalar subtype (for example integer, enumerated, real), is an attribute that represents the first value (lower bound) in the range of X. A'First, where A is an array, denotes the first index value. For more-dimensional arrays, A'First(N) denotes the first index value of the Nth dimension (N must be static). Example type My_Enum is (Enum1, Enum2, Enum3); type My_Int is range -1 .. 5; ... Assert (My_Enum'First = Enum1); OK Assert (My_Int'First = -1); OK Assert (My_Int'First = 0); Wrong! See also Wikibook Ada Programming Ada Programming/Attributes Last Range Ada Reference Manual 13 3 Operational and Representation Attributes K Language-Defined Attributes First