Question
Which of the following statements are false ? - Each class can define a constructor for custom object initialization. - A constructor cannot specify parameters.
Which of the following statements are false?
- Each class can define a constructor for custom object initialization. | ||
- A constructor cannot specify parameters. | ||
- C++ requires a constructor call for every object that's created. | ||
- A constructor is a special member function that must have the same name as the class. - If a class defines a constructor, the compiler will not create a default constructor for that class. - An uninitialized fundamental-type variable is implicitly initialized to zero. - A string's default constructor initializes the object to the empty string - You must list an access specifier for every member. - Declaring data members private is known as data hiding. private data members are encapsulated (hidden) in an object and can be accessed only by member functions of the object's class.
|
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started