6.1

Array Basics

AP Computer Science A

Declaring an array

Creating an array with `new`

Default values by type

Initializer list

Accessing elements

Modifying elements

The `.length` property

Accessing the last element

ArrayIndexOutOfBoundsException

Arrays are reference types

Memory diagram

Comparing arrays

Complete example: Student grade tracker

AP Exam Tips

Common Mistakes

Key Vocabulary