Skip to content
Sharp

Exceptions · interview question

When is an unchecked exception often the clearer choice?

Multiple choiceMediumchapter-6-curatedpremiumexceptionschecked-vs-unchecked-exceptions
Choose one answer
Answer and explanation

Correct answer

D. When the problem is invalid input, misuse, or a broken assumption

Why

Unchecked exceptions are often better for invalid calls, broken invariants, and programmer mistakes. They usually signal that the current usage is wrong rather than a normal recoverable condition the caller should negotiate.

Test yourself on Exceptions

A free test with instant, explained results. No account needed.

Start free test
All Exceptions questions →