Can try statements be nested?
Answers were Sorted based on User's Feedback
Answer / manikandansit
yes we can.
class test
{
public static void main(String []adsfdasf)
{
try
{
try
{
}catch(Exception e)
{
}
}catch(Exception e)
{
}
}
}
| Is This Answer Correct ? | 9 Yes | 0 No |
Answer / devarathnam
Hi... yes ,"try" statements can be nested, but each try
must be having the one "catch" statement.Without "catch"
and "finally" statements ,"try" statement will be illegal
| Is This Answer Correct ? | 7 Yes | 0 No |
When should I use singleton?
What are methods of a class?
What is a buffer in computer?
Which is fastest collection in java?
what are upcasting and downcasting?
What is a website container?
Can we compare two strings in java?
Why string is popular hashmap key in java?
What is the point of polymorphism java?
What is entry set in java?
what is main difference between architecture,framework and design pattren
What are java methods?