Exception Handling

© examsiri.com
Question : 12 of 24
 
Marks: +1, -0
Given:
1. static void test() {
2.   try {
3.    String x = null;
4.    System.out.print(x.toString() + " ");
5.   }
6.   finally { System.out.print("finally "); }
7. }
8. public static void main(String[] args) {
9.   try { test(); }
10.   catch (Exception ex) { System.out.print("exception "); }
11. }

What is the result?
Go to Question: