Exception Handling Flashcards
1
Q
What is an exception?
A
An exception is an error message.
2
Q
What are the two types of Exceptions?
A
Checked and Unchecked Exceptions
3
Q
What is a checked exception?
A
This is a compile time error, that the compiler forces you to handle with the use try/catch blocks and the throw/throws keywords.
4
Q
List 3 Examples of checked exceptions.
A
- IOException
- FileNotFoundException
- SQLException
5
Q
What is an unchecked exception?
A
These are errors or exception that occur at runtime
6
Q
What are some examples of unchecked exceptions?
A
ArithmeticException
ArrayIndexOutOFBoundsException
NullPionterException