Quiz 10

¡Supera tus tareas y exámenes ahora con Quizwiz!

A

A struct can contain members with varying data types. A. True B. False

A

A structure __________ contain members of the same data type. A. can B. is likely C. shouldn't D. none of the answers E. cannot

A

A structure pointer contains A. the address of a structure variable B. the name and address of the structure tag C. the dereferenced address of a structure tag D. e address of a structure tag E. none of the answers

B

Given the following structure declaration, Employee is struct Employee { --> string name; --> int idNum; } ; A. a member B. a tag C. an array D. none of the answers E. a keyword

B

If Circle is a structure, what does the following statement do? Circle *pcirc = nullptr; A. None of the answers B. It declares a structure pointer called pcirc initialized with a null pointer. C. The statement is illegal in C++. D. It declares an empty structure variable named *pcirc. E. It initializes a null pointer with the value of the Circle pointer.

B

If a is a structure variable and p, a pointer, is a member of the structure, what will the following statement do? cout << *a.p; A. none of the answers B. output the dereferenced value pointed to by p C. output the value stored in a D. output the address stored in p E. result in a compiler error

D

Passing a structure as a constant reference parameter to a function A. can potentially result in changes to the structure's members B. will always change the structure's members C. none of the answers D. guarantees not to result in changes to the structure's members E. will change if dereference the structure's member

C

To dereference a structure pointer, the appropriate operator is A. a input operator (>>) B. the <- operator C. the -> operator D. none of the answers E. the ampersand (&)

E

Which of the following is an example of a C++ primitive data type? A. long int B. unsigned short int C. unsigned char D. long double E. all of the answers

C

Which of the following will allow you to access structure members? A. the #include<structaccess> directive B. none of the answers C. the dot operator D. the structure access operator E. the getmember function


Conjuntos de estudio relacionados

Chapter 44: Assessment and Management of Patients with Biliary Disorders

View Set

Ohio Health Insurance Exam (Attempt 1)

View Set

Unit 10 - IN CLASS Cold War Beginnings & Impact on Society (1945-1959)

View Set

Concepts of Care for Patients with Musculoskeletal Trauma: Chapter 47 10th Edition

View Set

Ch. 1 Structuralism and Functionalism

View Set