A Class is a template or a blue print of an Object to be created. An Object is an instance of a Class. A Class...
When we want to overload a method, we need to make sure that the method name remains same. But method...
During the run time the behavior of an Object can change based on its run time state. Due to this run time...
Since String objects are cached in a String pool, it makes sense to make the String immutable. The cached String...
Java supports Method overloading but does not support operator overloading. It would make the design more...
Since JSP pages are dynamically compiled into servlets, the programmers can easily make updates to the presentation layer code...
Both Cookie and Session are used during communication between Client and Server. The Client can disable...
Throwable class is the superclass of Exception and Error classes in Java...
To make an Object eligible for Garbage collection, just make sure that it is unreachable to the program in which...
Collection interface just specifies groups of objects known as elements. Each concrete implementation of a Collection...
Whenever an object is passed by value, it means that a copy of the object is passed. Even if changes are...
Enumeration interface is a read-only interface. It has better performance than Iterator. It is almost twice as fast...
In Java, Document Object Model (DOM) parser loads the whole XML into memory and creates a tree based...
We can print an array by using methods of Arrays class. We can either use Arrays.toString() method or we can...
The volatile keyword guarantees global ordering on reads and writes to a variable. This implies that every thread...
A compile time constant is public static final variable. The public modifier is optional here. At compile time, they...
We can use memory management related methods provided in java.lang.Runtime class to get the free memory...
In Java, Stack and heap are memory areas available to an application. Every thread has its own stack. It is used...
Following are the different states of a Thread in Java..
There are certain downsides to Multithreading...