What will happen when you attempt to compile and run the following code?
#include
#include
#include
using namespace std;
class A
{
int a;
public:
A(int a) {this?>a = a; c++;}
~A() { c??;}
static int c;
};
int A::c(0);
int main ()
{
A t[] = {0, 1, 2, 3, 4, 5, 6, 7, 8 , 9};
vectorv1(t, t+10);
dequed1(v1.begin(), v1.end());
deque d2;
d2 = d1;
cout< return 0; } How many objects of type A will be created:
Currently there are no comments in this discussion, be the first to comment!