摘要:
1.需要进行深拷贝的时候必须重载赋值操作 === 重载赋值操作必然需要实现深拷贝 include include using namespace std; class Test { int m_pointer; public: Test () { m_pointer == NULL; } Test 阅读全文
摘要:
1.问题: string类 对象还具备c方式字符串的灵活性吗?还能直接访问单个字符吗? === 答案:可以按照c字符串的方式使用string对象 string s = "a1b2c3d4e"; int n = 0; for(int i = 0; i include using namespace s 阅读全文