




Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!





55 people answered the survey Wednesday is review and ungraded quiz Remember midterm on Friday! Post-HW2 midterm material questions today Sample midterm tomorrow
Arrays are convenient ways to store similar data types Much like how we have been thinking of Strings as a list of characters Arrays are also indexed starting from zero
When making an array, you need both a type and a length. The format for making an array is below: Type, [] means array variable name length of array
Arrays can be initialized by the following: If you try an access an array element that has not been initialized, your program will crash Arrays have a .length variable (similar to Strings) (See: ArrayPrintf.java)
A char array is not a String While the important data in String is a char array, classes have methods unlike arrays More examples: (See: ArrayAverage.java) (See: Fibonacci.java)