Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

what is difference between Exception and Error?

Answer Posted / sandeep tyagi

The functional diiference, in terms of the compiler, is
that you don't have to declare errors in throws clauses on
methods, or catch them.

Conceptually, an Error means something has gone wrong with
your program, which should usually give up and crash,
whereas an exception is for an unusual situation that you,
as a programmer, anticipated as a possibilty. So, for
example, a divide-by-zero is an Error, but attempting to
read a file and finding it doesn't exist is an Exception.

Is This Answer Correct ?    78 Yes 55 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is tree in java?

860


What is thread life cycle in java?

1006


Explain the concept of hashtables?

1058


What does the “static” keyword mean? Can you override private or static method in java?

1038


Explain about exception propagation?

974


String class is defined under which package in java?

1019


What is the difference between static and global variables and also define what are volatile variables?

987


If I only change the return type, does the method become overloaded?

874


When is the arraystoreexception thrown?

961


What is the tradeoff between using an unordered array versus an ordered array?

1161


Is null a keyword in java?

916


What is difference between equal and == in java?

905


Is char a data type in java?

918


Can we declare a class as abstract without having any abstract method?

948


How do you input a string in java?

994