IBM Interview Question

implement custom arraylist in java