JAVA Exceptions In which of the following package Exception class exist? java.util java.file java.net java.lang java.io java.util java.file java.net java.lang java.io ANSWER DOWNLOAD EXAMIANS APP
JAVA Exceptions What will be the result of executing the following code?public class Test{ public void divide(int a, int b){ try{ int c = a / b; }catch(Exception e){ System.out.print("Exception "); }finally{ System.out.println("Finally"); } public static void main(String args[]){ Test t = new Test(); t.divide(0,3); }} Prints out: Exception Finally None of these Compile with error Prints out: Exception Prints out: Finally Prints out: Exception Finally None of these Compile with error Prints out: Exception Prints out: Finally ANSWER DOWNLOAD EXAMIANS APP
JAVA Exceptions Which of the following blocks execute compulsorily whether exception is caught or not. throws catch finally throw throws catch finally throw ANSWER DOWNLOAD EXAMIANS APP
JAVA Exceptions The class at the top of exception class hierarchy is ................. Exception ArithmeticException Throwable Object Exception ArithmeticException Throwable Object ANSWER DOWNLOAD EXAMIANS APP
JAVA Exceptions What will be the output?class MyClass{ public String test(){ try{ System.out.print("One"); return ""; } finally{ System.out.print("Two"); } }}public class Test{ public static void main(String args[]){ MyClass m = new MyClass(); m.test(); }} Compilation Error One Two Two None of these One Compilation Error One Two Two None of these One ANSWER DOWNLOAD EXAMIANS APP
JAVA Exceptions Exception generated in try block is caught in ........... block. throws finally catch throw throws finally catch throw ANSWER DOWNLOAD EXAMIANS APP