int static x与static int x的区别
# include <iostream.h>
class Point{
public:
void output()
{}
void static init()
{x=0;
y=0;}
private:
int static x;//static int x时就不能通过链接了,我知道类的静态成员变量应该在类的定义前初始化。
int static y;//但这样可以编译通过
};
void main ()
{ //Point pt;
//pt.output();
//pt.init();
Point::init();
// Point::output();