Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Completes each of the following definitions by filling each of the blank with th

ID: 3770313 • Letter: C

Question

Completes each of the following definitions by filling each of the blank with the appropriate word or phrase:

1. In C++ “__________” variables are declared using the qualifier static.

2. The purpose of a “_______________” is to deallocate memory to class instances.

3. Class or Variable “____________” serve as a model for a family of classes or variables in functions` definitions.

4. The variable scope “____________” means that the names of the data attributes and function members are local to the scope of their class.

5. “_______________” means that the function’s action is determined by the object using it.

6. The purpose of a constructor is to allocate “_________” to class instances.

7. Unlike a method, which is always a member of a “__________”, a function is a non-class procedure.

8. The scope “_______________” allows subclasses to access private variables of their parent classes.

Explanation / Answer

Answer:

1. In C++ “static” variables are declared using the qualifier static.Static variables when used inside function are initialized only once, and then they hold there value even through function calls

2. The purpose of a “ destructor” is to deallocate memory to class instances. a destructor is a special class member function that "destroys" objects of that class type. Generally, to destroy an object means to deallocate or release the resources used by that object.

3. Class or Variable “declaration” serve as a model for a family of classes or variables in functions` definitions.I am not sure if this the answer you want. i wish if it was more specific.

4. The variable scope “ Private” means that the names of the data attributes and function members are local to the scope of their class.

5. “procedure calls/functions call defines the action stated in the body of function” means that the function’s action is determined by the object using it.

6. The purpose of a constructor is to allocate “ memory ” to class instances.A class constructor is a special member function of a class that is executed whenever we create new objects of that class. constructor initialise object and hence memory allocation.

7. Unlike a method, which is always a member of a “ Class”, a function is a non-class procedure.In object-oriented programming, a method is a subroutine (or procedure or function) associated with a class.

8. The scope “_______________” allows subclasses to access private variables of their parent classes.Private variables/objects are only accessible within the class defining them. It cant be inherited otherwise if it is accessible outside the class what is the matter to define the object as private.

Thanks

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote