Mike Gualeni wrote:Hello
Possibly found an errata. The answer in the book on question 12 on page 410, Chapter 7 Concurrency, is B but it's incorrect.
The method signature is: and throws an Interrupted Exception. And in the question mentioned above, the exception is not caught or declared to be thrown!
And that's why answer F should be correct. If the exception is caught or declared, answer B would be correct.
Greetings
Michael
Okay, I saw this:
Code fragments: A code fragment is a small section of source code that is presented without its context. Assume that all necessary supporting code exists and that the supporting environment fully supports the correct compilation and execution of the code shown and its omitted environment.
But do I have to assume everywhere if an exception is not caught or declared that a main method with the right throws Exception is surrounded'??