R
Q. How many of the String objects are eligible for garbage collection right before the end of the main method?
public static void main(String[] fruits) { String fruit1 = new String("apple"); String fruit2 = new String("orange"); String fruit3 = new String("pear"); fruit3 = fruit1; fruit2 = fruit3; fruit1 = fruit2; }
No solution found for this question.
Add Solution and get +2 points.
You must be Logged in to update hint/solution
Be the first to start discuss.
Q. What is the advantage of EXE files?
Q. Which method is used for an SQL statement that is executed frequently?
Q. The same import package/class be called twice in java?
Q. Which method is used to add a new line to file in Java?
Q. The object is created with new keyword
Q. The keywords reserved but used in the initial version of JAVA are:
Q. What is the output of a Logical AND (&) operation if both inputs/operands are true?
Q. One if or else if statement inside another if or else if statement is
Q. Which of the following classes can catch all exceptions which cannot be caught?
Discusssion
Login to discuss.