What is “try and catch” in java

Answer Posted / reshma

TRY AND CATCH BLOCKS ARE USED FOR EXCEPTION HANDLING SOMETIMES PROGRAMMER GIVE WRONG INPUT THEN EXCEPTION OCCCUR,IN TRY BLOCK WE LOGIC OF PROGRAM IS WRITTEN WHERE EXCEPTION OCCURED THAT EXCEPTOINS ARE THROWN TO CATCH BLOCK.CATCH BLOCK CATCHES THE EXCEPTION THROWN BY TRY BLOCK.

Is This Answer Correct ?    7 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the data types supported by java? What is autoboxing and unboxing?

541


How to create a custom exception?

567


What are the advantages of encapsulation in java?

547


What does int argc char * argv [] mean?

508


What is variable in java?

516






Is array an object in java?

541


What is difference between calling start() and run() method of thread?

555


What is called module?

561


What are annotations in java?

619


What is the use of arraylist class in java?

547


Is 64bit faster than 32 bit?

573


What's the default access specifier for variables and methods of a class?

507


What is anagram in java?

512


Can an abstract class be a final class?

527


What do you mean by mnemonics?

525