IndiaBIX
IndiaBIX
Start typing & press "Enter" or "ESC" to close
  • Home
  • Jobs
  • Results
  • Current Affairs
  • GK
  • Online Test
  • HR Interview
  • BLOG

Objects and Classes (2)

  • Home
  • Computer Science & Engineering
  • C++ Programming Questions and Answers
  • Objects and Classes
9. 

What does the class definitions in following code represent?

class Bike
{
Engine objEng;
};
class Engine
{
float CC;
};

A. kind of relationship
B. has a relationship
C. Inheritance
D. Both A and B

Answer: Option B

Explanation:

No answer description available for this question. Let us discuss.
View Answer Discuss Workspace Report

10. 

Which of the following statements about virtual base classes is correct?

A. It is used to provide multiple inheritance.
B. It is used to avoid multiple copies of base class in derived class.
C. It is used to allow multiple copies of base class in a derived class.
D. It allows private members of the base class to be inherited in the derived class.

Answer: Option B

Explanation:

No answer description available for this question. Let us discuss.
View Answer Discuss Workspace Report

11. 

Constructor is executed when _____.

A. an object is created
B. an object is used
C. a class is declared
D. an object goes out of scope.

Answer: Option A

Explanation:

No answer description available for this question. Let us discuss.
View Answer Discuss Workspace Report

12. 

Which of the following also known as an instance of a class?

A. Friend Functions
B. Object
C. Member Functions
D. Member Variables

Answer: Option B

Explanation:

No answer description available for this question. Let us discuss.
View Answer Discuss Workspace Report

13. 

Which of the following type of data member can be shared by all instances of its class?

A. Public
B. Inherited
C. Static
D. Friend

Answer: Option C

Explanation:

No answer description available for this question. Let us discuss.
View Answer Discuss Workspace Report

14. 

Which of the following can access private data members or member functions of a class?

A. Any function in the program.
B. All global functions in the program.
C. Any member function of that class.
D. Only public member functions of that class.

Answer: Option C

Explanation:

No answer description available for this question. Let us discuss.
View Answer Discuss Workspace Report

15. 

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

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

Answer: Option C

Explanation:

No answer description available for this question. Let us discuss.
View Answer Discuss Workspace Report

16. 

Which of the following statement is correct with respect to the use of friend keyword inside a class?

A. A private data member can be declared as a friend.
B. A class may be declared as a friend.
C. An object may be declared as a friend.
D. We can use friend keyword as a class name.

Answer: Option B

Explanation:

No answer description available for this question. Let us discuss.
View Answer Discuss Workspace Report

  • 1
  • 2
  • 3

Questions & Answers

Aptitude Chemical Engineering Civil Engineering Computer Science & Engineering Current Affairs Data Interpretation Electrical & Electronics Engineering Electronics & Communication Engineering General Knowledge Logical Reasoning Mechanical Engineering Non Verbal Reasoning Verbal Ability Verbal Reasoning

Interviews

HR Interview

Jobs

Sarkari Jobs

Results

Rojgar ResultSarkari Result

Admission

Admission 2023

Admit Card

Admit Card 2023

Answer Key

Answer Key 2023
copyright
Privacy Policy
© 2025 IndiaBIX. All Rights Reserved.

Report