Categories
  Encyclosphere.org ENCYCLOREADER
  supported by EncyclosphereKSF

Array

From Conservapedia - Reading time: 1 min

In computer science, an array is a data structure which consists of a collection of homogenous data accessed via an index. The index is usually a scalar value, such as an integer. The index specifies one of the elements, or values, within the array. For instance, in the C++ programming language, the nth element of an array named array would be accessed via the following source code:

array[ n ]

Arrays may be single-dimensional, or mutli-dimensional (aka poly-dimensional). A 2-dimensional array with data consisting of numbers can be thought of as a form of mathematical Matrix. Although implementations vary, a multi-dimensional array can be conceptualized as an array of other arrays. For instance, a 3-dimensional array could be accessed as

array[ x ][ y ][ z ]

or (in a short-hand version) as

array[ x, y, z ]


Array may also refer to a collection of hardware components, such as a Disk array, or as a synonym to vector.

References[edit]


Licensed under CC BY-SA 3.0 | Source: https://www.conservapedia.com/Array
26 views | Status: cached on February 27 2023 00:42:15
↧ Download this article as ZWI file
Encyclosphere.org EncycloReader is supported by the EncyclosphereKSF