Which of the following best describes what happens when an object no longer has any references pointing to it?

a) The object is overwritten the next time the new operator is called.
b) The object is overwritten the next time the new operator is called using the same class.
c) The object is immediately deleted from memory.
d) The object is marked as garbage and its associated memory is freed when the garbage collector runs.
e) The object stays in memory for the remainder of the programs execution.


d) The object is marked as garbage and its associated memory is freed when the garbage collector runs.

Computer Science & Information Technology

You might also like to view...

A(n) __________ program displays on the screen a list of operations it can perform and allows the user to select the desired operation.

Fill in the blank(s) with the appropriate word(s).

Computer Science & Information Technology

What is displayed by the following code? public static void main(String[] args) { String[] tokens = "Welcome to Java".split("o"); for (int i = 0; i < tokens.length; i++) { System.out.print(tokens[i] + " "); } }

a. Welcome to Java b. Welc me to Java c. Welc me t Java d. Welcome t Java

Computer Science & Information Technology

If NEW_TIME is a constant equal to 86400, which of the following will set a cookie to expire in a day?

a. ``` time() + NEW_TIME ``` b. ``` time() + NEW_TIME + 1 ``` c. ``` time() + (NEW_TIME * 24) ``` d. ``` time() = NEW_TIME + 24 ```

Computer Science & Information Technology

Google+ allows you to add a person to multiple circles

Indicate whether the statement is true or false

Computer Science & Information Technology