Vendor: Oracle Exam Code: 1Z0-803 Exam Name: Java SE 7 Programmer I QUESTION 1 Given: import java.io.IOException; public class Y { public static void main(String[] args) { try { doSomething(); } catch (RuntimeException e) { System.out.println(e); } } static void doSomething() { if (Math.random() > 0.5) throw new IOException(); throw new RuntimeException(); } }
Continue reading