What will happen if we write code like:
try{}catch(exception e)catch(IOException i)
Answer Posted / mathi
Ignoring the incorrect syntax of the Try\Catch Block, it
will never reach the IOException portion of the
Catch......the first catch will always be triggered due to
it only Catching type Exception.
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
Name few java 8 annotations ?
What is functional interface in java example?
What is java util hashmap?
Which way a developer should use for creating thread, i.e. Sub classing thread or implementing runnable.
How can I right-justify a string?
What does the “static” keyword mean?
How are variables stored in memory?
Can we declare a class as static?
What are jee technologies?
What is natural ordering in java?
How we can skip finally block of exception even if some exception occurs in the exception block in java?
What is the difference between a constructor and a method?
How will you serialize a singleton class without violating singleton pattern?
What's the purpose of using break in each case of switch statement?
Can a static class have a constructor java?