Presentation is loading. Please wait.

Presentation is loading. Please wait.

Learning Plan 5 Arrays.

Similar presentations


Presentation on theme: "Learning Plan 5 Arrays."— Presentation transcript:

1 Learning Plan 5 Arrays

2 Arrays A variable stores ones value
An array is just like a variable, but can hold more than one value

3 Arrays Int[] sale = new int[20]; sale[0] = 20000; sale[1] = 30000; ..
System.out.println(sale[0]); System.out.println(sale[19);

4 Using Loops with Arrays
Int[] sale = new int[20]; sale [0] = 20000; sale [1] = 30000; .. Sale[19] = ; For (int i = 0; I < 20; i++) { System.out.println(sale[i]); }

5 Real World Array Application
Amazon - searches online database of products Results are returned in form of an array Programmatically loop through results and display products


Download ppt "Learning Plan 5 Arrays."

Similar presentations


Ads by Google