The following program has a compiler error, runtime error, a…

Questions

The fоllоwing prоgrаm hаs а compiler error, runtime error, and semantic error. State which line(s) correspond to each type of error and why. 1. public class A { 2. private int[] arr = new int[3]; 3. private char 1letter = 'A'; 4.      5. public A(int num) { 6.       arr[3] = num; 7. } 8. 9.      public int getFirstArrayElement() {10. return arr[1];11. }12. }