Ask Question
25 July, 09:18

When a field is declared static, there will be:

A. a copy of the field in each class object

B. only one copy of the field in memory

C. a copy of the field for each static method in the class

D. only two copies of the field in memory

+1
Answers (1)
  1. 25 July, 09:26
    0
    B. only one copy of the field in memory

    Explanation:

    A static method is sort of a description of a class but is not part of the objects that it generates. Crucial: A program may perform a static method without constructing an object first! All other functions (those not static) only occur when they're member of an object. Thus it is necessary to build an object before they could be executed.

    Therefore, when an static field is declared static, there will be:

    B. only one copy of the field in memory
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “When a field is declared static, there will be: A. a copy of the field in each class object B. only one copy of the field in memory C. a ...” in 📗 Chemistry if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers