go to home page   go to next page

created: 11/25/98; revised: 04/21/99, 11/25/99, 01/24/00, 07/20/02, 05/28/03, 02/02/06, 08/15/14

CHAPTER 48 — Arrays as Parameters

Chapter Topics:

The last two chapters were about arrays. The example programs used a main() method which contained the arrays and did all the computing. This is not the way programs are usually written. Usually, arrays (and other forms of data) are manipulated by passing them as parameters to methods. Each method is like a machine that does something with an array. For example, there may be a method that finds the maximum element of an array, or a method that adds up all the elements in an array.


(Review:) What is a parameter?