211k views
5 votes
Look at the following structure declaration.

struct Employee

{

string name;

int idNum;

};

In this declaration, Employee is

A.
a member

B.
a tag

C.
an array

D.
None of the above

1 Answer

7 votes

Answer:

B. a tag

Step-by-step explanation:

In the structure definition given below:

struct Employee

{

string name;

int idNum;

};

Employee corresponds to the tag of the structure. The tag is used to create additional instances of the structure. For example:

struct Employee e1;

struct Employee e2;

name and idNum are members of the Employee structure and are referenced using the dot notation. e.g.,

struct Employee e1;

e1.idNum=1;

User Ribena
by
5.2k points