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
how to create multithreaded program? : Java thread
What is protected access modifier?
What are thread priorities and importance of thread priorities in java?
Is double bigger than float?
Can we declare the main method of our class as private?
Can we change the value of static variable?
Differences between external iteration and internal iteration?
Does java have a compiler?
what is bmg file and how to create that files?what will it contailn?
Which programming language is most secure?
Can we create constructor in abstract class ?
What are the different types of inner classes?
What is an example of declaration?
What is lazy initialization in java?
What is the latest java version?