You refer to the member variable by preceding its name with the name of the . . . . . . . . in which it is defined.

Variable
Auto variable
Structure variable
Constant variable

The correct answer is: C. Structure variable

A member variable is a variable that is defined inside a structure. It is accessible to all the functions of the structure. To refer to a member variable, you need to precede its name with the name of the structure in which it is defined.

For example, consider the following structure:

struct Student {
int roll_number;
char name[20];
};

The member variables of the Student structure are roll_number and name. To refer to the roll_number member variable, you would write student.roll_number. To refer to the name member variable, you would write student.name.

The other options are incorrect because:

  • A variable is a location in memory that can store a value.
  • An auto variable is a variable that is declared inside a function and is only available within that function.
  • A constant variable is a variable whose value cannot be changed.

I hope this helps! Let me know if you have any other questions.

Exit mobile version