Arrays are useful for processing many data or generating many results at once into a compact contiguous structure. Loosely speaking, array structures allow one to manipulate many variables at once. An array is an indexed sequence of components. In mathematics, one is familiar with variables bearing indices like, for example, the vector coordinates x i or matrix elements m i,j . In most programming languages, indices start at zero and not at one as is often the case in mathematics. This simple 1-or-0 convention actually yields confusion to many novice programmers, and is therefore an important source of bugs to watch for.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Author information
Authors and Affiliations
Corresponding author
Rights and permissions
Copyright information
© 2009 Springer-Verlag London
About this chapter
Cite this chapter
Nielsen, F. (2009). Arrays. In: A Concise and Practical Introduction to Programming Algorithms in Java. Undergraduate Topics in Computer Science. Springer, London. https://doi.org/10.1007/978-1-84882-339-6_4
Download citation
DOI: https://doi.org/10.1007/978-1-84882-339-6_4
Published:
Publisher Name: Springer, London
Print ISBN: 978-1-84882-338-9
Online ISBN: 978-1-84882-339-6
eBook Packages: Computer ScienceComputer Science (R0)