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 |
Why are constructors used?
give me the answer of this code class A extnds String This code we can write r not in Java? Explain?
What restrictions are placed on method overloading in java programming?
What is keyword and identifier?
What is n in java?
How does queue work in java?
What is stringbuffer in java?
Difference between JDK, JRE, JVM
16 Answers Deloitte, HCL, Mind Tree, Oracle, Reliance, TCS, ThinkBox,
What technique can be employed to compare two strings?
what difference between throw and throws in exception handling.
how would you implement a thread pool? : Java thread
Why Static variable required in java?For ex,class A { static int a; int b; } Why static is required?