6. To expose a data member to the program, you must declare the data member in the _____ section of the class

A. common
B. exposed
C. public
D. unrestricted
E. user


Correct Answer:  C. public

7. Evaluate the following expression: 3 >6&&7>4

A. True
B. False


Correct Answer:  B. False

8. Which of the following are valid characters for a numeric literal constant?

A. a comma
B. a dollar sign ($)
C. a percent sign (%)
D. a space
E. None of the above


Correct Answer:  E. None of the above

9. A function that changes the state of the cout object is called a(n) _____

A. member
B. adjuster
C. manipulator
D. operator


Correct Answer:  C. manipulator

10. A C++ program contains a function with the header int function(double d, char c). Which of the following function headers could be used within the same program?

A. char function(double d, char c)
B. int function(int d, char c)
C. both (a) and (b)
D. neither (a) nor (b)


Correct Answer:  B. int function(int d, char c)

Comments

No comments yet. Why don’t you start the discussion?

Leave a Reply

Your email address will not be published. Required fields are marked *

five × two =