X hits on this document

166 views

0 shares

0 downloads

0 comments

4 / 63

Copyright ©2004 Pearson Addison-Wesley. All rights reserved.

8-4

Array Terminology (2)

Each element of the array x may contain a single value of type double, so a total of eight such numbers may be stored and referenced using the array name x.

To process the data stored in an array, we reference each individual element by specifying the array name and identifying the element desired.

The elements are numbered starting with 0

An array with 8 elements has elements at 0,1,2,3,4,5,6, and 7

The subscripted variable x[0] (read as x sub zero) refers to the initial or 0th element of the array x, x[1] is the next element in the array, and so on.

The integer enclosed in brackets is the array subscript or index and its value must be in the range from zero to one less than the array size.

Document info
Document views166
Page views166
Page last viewedSat Dec 10 02:30:14 UTC 2016
Pages63
Paragraphs754
Words4119

Comments