--:--









Quiz for throw vs throws

Course: JAVA | Subject: Java | Topic: Exception Handling



Logo

Q1: What does the 'throw' keyword do in Java?

Logo

Q2: Which keyword is used in a method signature to declare an exception?

Logo

Q3: Which of the following is the correct syntax for 'throw'?

Logo

Q4: What is the return type of the 'throw' keyword?

Logo

Q5: Can 'throws' be used to handle RuntimeExceptions?

Logo

Q6: Which exception type must be declared or handled in Java?

Logo

Q7: Which statement about 'throw' is true?

Logo

Q8: Where is 'throws' used in Java code?

Logo

Q9: Which is a valid method declaration using 'throws'?

Logo

Q10: Can you throw more than one exception using a single 'throw' statement?

Logo

Q11: Which of the following is a checked exception?

Logo

Q12: What happens if a checked exception is not declared using 'throws'?

Are you ready to start test? Set your time limit