Close
Register
Close Window

Show Source |    | About   «  2.2. Polymorphism   ::   Contents   ::   2.4. Generics Intro  »

2.3. Java Arrays

2.3.1. Objectives

  • Trace code that uses arrays

  • Write code to create and process arrays including finding a sum, average, max, and min values

  • Trace and write code to perform a linear search on an array

  • Trace and write code to insert or remove an item anywhere in an array

2.3.2. Interactive: Java Array Basics

Follow Along, Practice and Explore

Download to run and explore the java file (see below) from the video on your own in eclipse. You may download the standalone *.java file for this example. To run the standalone *.java file you will need to
  1. create a new Eclipse project, then

  2. create a package within the project called “example” (the package named at the top of the class MUST match the package the file is placed in within the Eclipse project), and finally

  3. download and import the standalone *.java file(s) to the created package.

ArrayBasics.java

2.3.3. Checkpoint 1

2.3.4. Programming Practice: Java Arrays 1

2.3.6. Checkpoint 2

2.3.7. Interactive: Java Array Removing, Inserting, & Tips

Follow Along, Practice and Explore

Download to run and explore the java files (see below) from the video on your own in eclipse. You may download the standalone *.java file for this example. To run the standalone *.java file you will need to
  1. create a new Eclipse project, then

  2. create a package within the project called “example” (the package named at the top of the class MUST match the package the file is placed in within the Eclipse project), and finally

  3. download and import the standalone *.java file(s) to the created package.

ArrayRemove.java ArrayInsert.java

2.3.8. Checkpoint 3

2.3.9. Programming Practice: Java Arrays 2

   «  2.2. Polymorphism   ::   Contents   ::   2.4. Generics Intro  »

nsf
Close Window