Blog Archives

Java exception handling interview questions and answers

Q1. What is the difference between a runtime exception and a checked exception?
A1. You must either catch or throw a checked exception. The unchecked exception (aka Runtime exception) does not …



Java String & Array limitations and OutOfMemoryError

Q1. What is the maximum possible length of a Java String & how much heap space do you need to store the maximum possible String object?
A1. A Java String internally …



SQLException handling – recoverable & irrecoverable scenarios

Q1. What is wrong with SQLException? A1. When a SQLException occurs, you do not necessarily know what went wrong. It could be a temporary failure that correct itself with time like …



Top 5 Core Java Exceptions and best practices

#1: ConcurrentModificationException Getting a ConcurrentModificationException when trying to modify (i.e. adding or removing an item) a collection while iterating. The following code throws a ConcurrentModificationException.



800+ Java Interview Q&As

Prepare to fast-track & go places
with multi-offers to choose from & increased earning potential. Expand your horizons along the way by taking the road less travelled.
Learn by categories on the go...
Learn by categories such as FAQs – Core Java, Key Area – Low Latency, Core Java – Java 8, JEE – Microservices, Big Data – NoSQL, etc. Some posts belong to multiple categories.
Top