4
为什么在C++中允许静态类对象?他们的用途是什么?静态类对象
#include<iostream>
using namespace std;
class Test {
static Test self; // works fine
/* other stuff in class*/
};
int main()
{
Test t;
getchar();
return 0;
}
+1完美答案:) – 2012-01-28 09:34:00