Creating an object requires two steps that are shown in the example below:Employee myAssistant;myAssistant = new Employee();What do these statements accomplish?
What will be an ideal response?
Defining an Employee object named myAssistant requires two steps-you must declare a reference to the object, and then you must actually set aside enough memory to hold the object. When you declare the myAssistant instance of the Employee class (as in the first statement), you are notifying the compiler that you will use the identifier myAssistant. However, you are not yet setting aside computer memory in which the object named myAssistant can be stored. To allocate the needed memory and instantiate the object, you must use the new operator (as in the second statement).
You might also like to view...
XHTML does not recognize breaks inserted in the text editor by using the ________ key
Fill in the blank(s) with correct word
If processes must be performed in a specific sequence, the information should be documented in the _____.
A. leveling guide B. process descriptions C. data dictionary D. data flow diagram (DFD)
Which of the following policies could be implemented to help prevent users from displaying their login credentials in open view for everyone to see?
A. Privacy B. Clean desk C. Job rotation D. Password complexity
Contingency planning falls into the _________ class of security controls.
Fill in the blank(s) with the appropriate word(s).