Two arrays of primitives are equal if they contain the same number of elements, and all corresponding pairs of elements in the two arrays are equal.
The solutions to these two problems rely on the Arrays utility class. The following sections give the solutions to these problems.