Abstract
This chapter examines the question of how to iterate through a collection of objects. The chapter examines external iteration, in which you write a loop to examine the elements, and internal iteration, in which you call a method to perform the loop for you. The methods of the Java Stream interface are discussed, which provideĀ a powerful example of internal iteration.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Author information
Authors and Affiliations
Rights and permissions
Copyright information
Ā© 2019 Edward Sciore
About this chapter
Cite this chapter
Sciore, E. (2019). Iterables and Iteration. In: Java Program Design. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4842-4143-1_6
Download citation
DOI: https://doi.org/10.1007/978-1-4842-4143-1_6
Published:
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4842-4142-4
Online ISBN: 978-1-4842-4143-1
eBook Packages: Professional and Applied ComputingApress Access BooksProfessional and Applied Computing (R0)