Which of the following keyword is used for manually throwing an exception?
Correct Answer: throw
Explanation:
Note: This Question is unanswered, help us to find answer for this one
Java Skill Assessment
Your Skill Level: Poor
Retake Quizzes to improve it
More Java MCQ Questions
Output of the given console application? public class Main { public static void main(String[] args) { final int X = 9; int[][] a = {{5, 4, 3}, {9, 7, 2}, {1, 6, 8}}; for (int i=0; i<3; i++) { for (int j=0; j<3; j++) { if (a[i][j] == X) break; System.out.print(a[i][j] + ' '); } } } }
Output when the following code is compiled and run? public class Test { public static void main(String args[]) { int i; i = 3; System.out.println((int) i * 2.5 / 3.0); } }
Which statement is true about the given program? public class Test25 { public static void main(String[] args) { final byte a = 20; final byte b = 4; final byte c = a + b; System.out.println(c); } }
Output of the given program? public class Test71 { public static void main(String[] args) { System.out.println(new Child().toString()); } } class Parent { public String toString() { return this.getClass().getName(); } } class Child extends Parent {}
Output of the following program? class Upwork { public static void main(String args[]) { try { System.out.println('Hello World'); } finally { System.out.println('Finally executing'); } } }
Which statement is true about an anonymous inner class?
Which interface does java.util.Hashtable implement?
Which cannot directly cause a thread to stop executing?
Which statement is an incorrect statement?
You want subclasses in any package to have access to members of a superclass. Which is the most restrictive access that accomplishes this objective?