作用域问题!!
#include <iostream>
{ // begin new scope
Point4 point( 11, 22 );
} // end scope 问题就在与两个括号,有括号时,调用了Point4类的构造函数后立即调用它的析构函数,而去掉括号后(我亲自试过)最后调用析构函数析构对象point( 11, 22 );why????应该是作用域问题吧
#include "circle5.h" // Circle5 class definition
int main()
{
{ // begin new scope
Point4 point( 11, 22 );
} // end scope
cout << endl;
Circle5 circle1( 72, 29, 4.5 );
cout << endl;
Circle5 circle2( 5, 5, 10 );
cout << endl;
return 0; // indicates successful termination
} // end main