12/8/2005
Modern Programming Languages - Exceptions
1
Exercise 1A - List line numbers executed and output
1.
1. System.out.print("1");
2. try {
3.  System.out.print("2");
4.  if (true) throw new Exception();
5.  System.out.print("3");
6. }
7. catch (Exception e) {
8.  System.out.print("4");
9. }
10. finally {
11. System.out.print("5");
12. }
13. System.out.println("6");
Lines: 1-4, 7-13
Output: 1,2,4,5,6