C++: Classes And Objects Questions 5

Q.21.
What does the cerr represent?

A. Standard error stream
B. Standard logging stream
C. Input stream
D. Output stream


Q.22.
Which of the following is a valid class declaration?

A. Class A { int x; };
B. Class B { }
C. Public class A { }
D. Object A { int x; };


Q.23.
Which of the following keywords is used to control access to a class member?

A. Default
B. Break
C. Protected
D. Asm

Q.24.
How to access the object in the class?

A. Ternary operator
B. Scope resolution operator
C. Direct member access operator
D. None of the above

Q.25.
When struct is used instead of the keyword class means, what will happen in the program?

A. Access is public by default
B. Access is private by default
C. Access is protected by default
D. None of the mentioned