3. The only type of Error that can be handled are Checked exceptions.
You can handle or declare any of the three, but you MUST handle or declare checked exceptions.
1--If an exception isn't handled or declared properly does it cause compilation errors OR runtime errors?
You get a compiler error if your code doesn't handle or declare a checked exception. Otherwise, the code will
compile and run until a runtime exception (or error) is thrown, at which point it will stop and indicate there was an error or exception.
2--Does the code still compile?
see above.
3--What's the difference between use of the keywords "throws" & "throw"? I always think "throws" is actually throwing the exception
'throw' actually throws the exception. You use it like 'throw new Exception()', or say you are in a catch
block where you already have a reference to the exception in scope, you could 'throw io' where 'io' is a reference
to IOException.
'throws' is the keyword used to declare an exception in a method signature:
void makeStream(File f) throws IOException { ... }
4--Any good tips for nailing down Exceptions? The questions in the K&B SCJP6 book are pretty tricky (I can only imagine what the exam is going to be like).
k&b is all you'll need. Focus on the rules presented at first, not on the tricky questions posed. Make sure you can
understand the concepts of each rule and try writing some code that incorporates those concepts. Once you
understand the basics,
you should be able to successfully analyze all the questions.