classes and data abstraction

MCQsQuestion.com has 4 Question/Answers about Topic classes and data abstraction

Passing arguments to a destructor, or specifying return type to destructor, causes

Passing arguments to a destructor, or specifying return type to destructor, causes
  • A. Logical error
  • B. Syntax error
  • C. Run time error
  • D. Fatal error
  • Correct Answer: Option B

If a class wants to allow clients to read private data, class can provide a

If a class wants to allow clients to read private data, class can provide a
  • A. Get function
  • B. Set function
  • C. Allow function
  • D. Both A and B
  • Correct Answer: Option D

Constructors do not have

Constructors do not have
  • A. Initial value
  • B. Return value
  • C. Default value
  • D. None of them
  • Correct Answer: Option B

Aggregate data types built using data of other types, is called as

Aggregate data types built using data of other types, is called as
  • A. Functions
  • B. Structures
  • C. Elements
  • D. Pointers
  • Correct Answer: Option B