Assignment+2

ArrayList is mentioned, these can be used for both tasks
 * Assignment 2**

import java.util.*; ArrayList list = new ArrayList;

then list.add; list.remove;

files were introduced in Week6, see also Chaper 19 in the text
 * Task1**

for validation (of subjects), try regexp, e.g. for a licence plate: "[A-Z]{3}[0-9]{3}"

Array of e.g. String is easy, for ArrayList of Object there are several options: 1. keep the data sorted, i.e. when you input/add it put it in the right order 2. use java.util.Collections.sort 3. write your own sort code
 * Sorting**:

(I think #2 is the easiest if you can figure out the Comparable interface and the compareTo method - see Week 10)

you can have an ArrayList of a fixed type e.g. ArrayList list = new ArrayList;
 * Task2**