Given the class definition:
class CreateDestroy
{
public:
CreateDestroy() { cout << "constructor called, "; }
~CreateDestroy() { cout << "destructor called, "; }
};
What will the following program output?
int main()
{
for ( int i = 1; i <= 2; ++i )
CreateDestroy cd;
return 0;
}
a. constructor called, destructor called, constructor called, destructor called,
b. constructor called, constructor called,
c. constructor called, constructor called, destructor called, destructor called,
d. Nothing.
a. constructor called, destructor called, constructor called, destructor called,
You might also like to view...
IOPS is a measurement that takes into account only sequential reads and writes
Indicate whether the statement is true or false
To insert slides from another presentation into a current presentation, click the New Slide list arrow in the Slides group, then click Insert Slides. _________________________
Answer the following statement true (T) or false (F)