Lecture 23, CS 302-6, October 26
i. EC – posted
ii. Extra office hours – 3-4 Wednesday, 12:30-2:30 Thursday, Friday TBD
iii. Initializing 2d arrays – how do we know the size of the array? Based on another array…
i. Scores posted – forms page of website
ii. Regrades – request by next Wednesday 5pm
i. Given names:
ArrayList<String> namesCopy=new ArrayList<String>(names);
i. this means that you can still store the primitive values in the array list – it just needs the type of the wrapper class.
ii. Example on board of what it means to be boxed:
Double wrapper=29.95;
double x=wrapper;
i. Example – Random random in Program2
i. Must specify Type Parameter in both cases in method declaration.
public static ArrayList<Integer> methodName(ArrayList<Integer> aList)
{
}