Employee::Employee(const Employee& other):name(other.name), id(count) { ++co
//为什么出现//undefined reference to `Employee::count'//.hclass Employee{ public: Employee():name("NoName"), id(count) { ++count; } Employee(std::string strName):name(strName), id(count) { ++count; } virtual ~Employee(); Employee(const Employee& other); Employee& operator=(const Employee& other); protected: private: std::string name; int id; static int count;};//.cppEmployee::Employee(const Employee& other):name(other.name), id(count){ ++count;}