What is the difference between error and exception and
explain in simple words not whatever is given in the book.
Answer Posted / muffy.jad@gmail.com
An error is an irrecoverable condition occurring at runtime.
Such as OutOfMemory error. These JVM errors and you can not
repair them at runtime.
While exceptions are conditions that occur because of bad
input etc. e.g. FileNotFoundException will be thrown if the
specified file does not exist. Or a NullPointerException
will take place if you try using a null reference.
In most of the cases it is possible to recover from an
exception
| Is This Answer Correct ? | 26 Yes | 1 No |
Post New Answer View All Answers
What are the skills required for core java?
what is the difference between preemptive scheduling and time slicing? : Java thread
What is a jit compiler?
What is comparator in java?
How to solve the problem of generating the unique hash keys with hash function?
What are some alternatives to inheritance?
Explain the importance of import keyword in java?
What is arraylist class in java?
How garbage collection is done in java?
Can we make a constructor final?
Which data type is class in java?
Whats the difference between notify() and notifyall()?
What is the difference between && and & in java?
Can we create object of static class?
Difference between static binding and dynamic binding?