What is functional interface in java?
No Answer is Posted For this Question
Be the First to Post Answer
How can we make a class singleton?
What is array size in java?
Can java cast null?
How do you identify independent and dependent variables?
What is the default size of arraylist in java?
Explain importance of throws keyword in java?
What are different types of encoding?
public class Garbage { int a=0; public void add() { int c=10+20; System.out.println(c); System.out.println(a); } public static void main(String args[]) { Garbage obj=new Garbage(); System.gc(); System.out.println("Garbage Collected"); obj.add(); } } Above is a code in java used for garbage collection. object obj has been created for the class Garbage and system.gc method is called. Then using that object add method is called.System.gc method if called the obj should be garbage collected?
What is a conditional statement explain with example?
Explain about Superclass and Subclass?
What is the difference between a scrollbar and a scrollpane?
What is scope & storage allocation of static, local and register variables? Explain with an example.