Label the last 9 lines of code in the test program to the right as:

  • OK, everything works,
  • error, explain why

Use the heirarchy below:

Monster is the superclass, and Alien and Vampire are subclasses.

import java.util.ArrayList;
public class Tester
   public static void main(String[] args){
   Monster m;
   Vampire v;
   Alien a;
   ArrayList creepies = new ArrayList();
   m= new Monster();
   a = new Alien();
   m = creepies.get(0);
   v = (Monster)(creepies.get(0)); 
   a = (Alien)(creepies.get(0)); 
   m = (Monster)(creepies.get(0));
   m = (Vampire)(creepies.get(0));
   m = (Monster)(creepies.get(1));
   m = (Alien)(creepies.get(1));
   v = (Vampire)(creepies.get(1));
   a = (Alien)(creepies.get(1));
  |   |  
  Alien   Vampire