ITSS 3312 Lecture Notes - Lecture 3: Pus, Method Stub
Document Summary
Values = new int[3];// in order to define the array, u have to use. System. out. println(values[2]); public static void main(string[] args) { int value = 7; // here ur just assigning a value to a variable int[] values; // [] represents as array. where u can store multiple. // it says 3 items, but the numbering starts off at 0,1 and 2. values[0]=10; values[1]=20; values[2]=30; System. out. println(values[0]); // the "0" is calling the 1st item in the public class arrays { values under one variable. variable = "new" and add a data type with the # of items in the array. list. //but there is a much simpler way of doing the same thing above int[] numbers= {10,20,30}; for (int i =0; i