Q. In Java, can a method declare both "throws" and "throw" statements?

  • (A) No, a method can only declare one of them
  • (B) Only if the method is marked as "static"
  • (C) Yes, a method can declare both "throws" and "throw" statements
  • (D) Only if the method is marked as "final"
πŸ’¬ Discuss
βœ… Correct Answer: (C) Yes, a method can declare both "throws" and "throw" statements

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
104
Total Visits
πŸ“½οΈ
1 y ago
Published
πŸŽ–οΈ
Sandhya Thakur
Publisher
πŸ“ˆ
94%
Success Rate