Question

Some programmers are careful about using this within member functions to make clear the distinction between Parameter variabl

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Answer : Option 4 (Data members and other variables)

Explanation : this is a keyword whcih is used to refer a current object.means it is a reference variables whcih refers to current object.Object means it contains data members .And to make difference between data members and other variables even though they both variables have same names this keyword will make a clear distinction between data members and other variables

**********Comment me for any Queries and Rate me up**************

Add a comment
Know the answer?
Add Answer to:
Some programmers are careful about using this within member functions to make clear the distinction between...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Create a class called Skateboard. Skateboard has 3 private member variables and 3 public member functions.(C++,...

    Create a class called Skateboard. Skateboard has 3 private member variables and 3 public member functions.(C++, Visual Studios) Skateboard has the following 3 private member variables: 1) the brand of the skateboard (such as “Sector 9”)       2) the model of the skateboard (such as “Hot Steppa”) 3) the length of the skateboard in inches (such as “22”) Skateboard has the following 3 public member functions: a member function named print which does not have any return value or input...

  • in c++ Which of the following statements is false about structures in C++? Programmers must get...

    in c++ Which of the following statements is false about structures in C++? Programmers must get input for each individual member of the struct variable if they want the user to initialize it. Structures can be nested within each other. Structure data can be saved to and loaded from binary files. You can directly use the <<stream insertion operator on struct variables.

  • Multiple Choice Multiple Choice Section 2.1 - 2.2 Introduction to Classes Here is the start of...

    Multiple Choice Multiple Choice Section 2.1 - 2.2 Introduction to Classes Here is the start of a class declaration: class foo { public: void x(foo f); void y(const foo f); void z(foo f) const; ... Which of the three member functions can alter the PRIVATE member variables of the foo object that activates the function? A. Only x can alter the private member variables of the object that activates the function. B. Only y can alter the private member variables...

  • In C++ "_____" variables are declared using the qualifier static. The purpose of a "____" is...

    In C++ "_____" variables are declared using the qualifier static. The purpose of a "____" is to deallocate memory to class instances. Class or Variable "____" serves as a model for a family of classes or variables in functions definitions. The variable scope "____" means that the names of the data attributes and function members are local to the scope of their class. "_____" means that the function's action is determined by the object using it. The purpose of a...

  • Using the following definition (List.h file) for a list, implement the member functions (methods) for the...

    Using the following definition (List.h file) for a list, implement the member functions (methods) for the List class and store the implementation in a List.cpp file. Use a doubly linked list to implement the list. Write the client code (the main method and other non-class methods) and put in file driver.cpp. file: List.h typedef int ElementType; class node{ ​ElementType data; ​node * next; node* prev; }; class List { public: List(); //Create an empty list bool Empty(); // return true...

  • IntList Recursion Assignment Specifications: You will add some additional recursive functions to your IntList class as...

    IntList Recursion Assignment Specifications: You will add some additional recursive functions to your IntList class as well as make sure the Big 3 are defined. IntNode class I am providing the IntNode class you are required to use. Place this class definition within the IntList.h file exactly as is. Make sure you place it above the definition of your IntList class. Notice that you will not code an implementation file for the IntNode class. The IntNode constructor has been defined...

  • An array of class objects is similar to an array of some other data type. To...

    An array of class objects is similar to an array of some other data type. To create an array of Points, we write Point parray [4]; To access the object at position i of the array, we write parray [i] and to call a method on that object method, we write parray [i]. methodName (arg1 , arg2 , ...) ; To initialize an array of objects whose values are known at compile time, we can write Point parray [4] =...

  • Create class definitions using the following: Classes: Circle, Cube, Shape, Sphere, Square, ThreeDimensionalShape, TwoDimensionalShape Functions: Draw,...

    Create class definitions using the following: Classes: Circle, Cube, Shape, Sphere, Square, ThreeDimensionalShape, TwoDimensionalShape Functions: Draw, GetArea, GetDimensions, GetHeight, GetLength, GetSurfaceArea, GetVolume Members: height, length, width – all of type double Don’t actually write function implementations, just define the classes as you would in a header file. Use inheritance as appropriate. Use keywords such as “const” and “virtual” as appropriate. Make functions and members public, private, or protected as appropriate. Don’t forget constructors and destructors. Some classes may be abstract,...

  • // Inheriting member functions // Please Make all changes as noted below: // 1) Make sayHello...

    // Inheriting member functions // Please Make all changes as noted below: // 1) Make sayHello virtual function (hint this will be done in Person class // 2) Change main to create two Person pointer variables // 3) Set each pointer to one of the two objects already instantiated below // 4) Use the pointer variable to invoke the two sayHello() methods #include <iostream > #include <string > using namespace std ; class Person { protected : string name; int...

  • please show the steps and please make sure the solution readable and clear. please be careful...

    please show the steps and please make sure the solution readable and clear. please be careful about this. best regards. A combinational circuit with four inputs (A,B,C,D) and one output (Z) is designed as follows using an 8:1 multiplexer. Inputs A, B, C are connected to the select lines S2,S1,S, respectively. Multiplexer has the following values connected to the data inputs: 10.14 =D; 1, is = 0; 12,1 = 1; h 13,1, =D For the circuit given above a) Fill...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT