最近中文字幕高清中文字幕无,亚洲欧美高清一区二区三区,一本色道无码道dvd在线观看 ,一个人看的www免费高清中文字幕

為了賬號安全,請及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問題,去搜搜看,總會有你想問的

VS2015報(bào)兩個(gè)錯誤但不顯示錯誤內(nèi)容。。。誰幫忙看看

VS2015報(bào)兩個(gè)錯誤但不顯示錯誤內(nèi)容。。。誰幫忙看看

C++
饕餮不吃rou 2016-06-15 21:55:20
#include <iostream>#include <string>using namespace std;/*** 定義類:Student* 數(shù)據(jù)成員:m_strName* 無參構(gòu)造函數(shù):Student()* 有參構(gòu)造函數(shù):Student(string _name)* 拷貝構(gòu)造函數(shù):Student(const Student& stu)* 析構(gòu)函數(shù):~Student()* 數(shù)據(jù)成員函數(shù):setName(string _name)、getName()*/class student{public: student() {? cout << "student()" << endl; } student(string _name)? {? m_student = _name; cout << "student("<<_name<<")"<< endl; } student(const student& stu)? { cout << "const student& stu" << endl; } ~student()? { cout << "~student()" << endl; } void setName(string _name) { m_student = _name; } string getName() { return m_student; }private: string m_student;};int main(void){ // 通過new方式實(shí)例化對象*stu student *stu = new student; // 更改對象的數(shù)據(jù)成員為“慕課網(wǎng)” stu-> setName( "慕課網(wǎng)"); // 打印對象的數(shù)據(jù)成員 cout << stu->getName() << endl; delete stu; stu = NULL; return 0;}
查看完整描述

1 回答

  • 1 回答
  • 0 關(guān)注
  • 3722 瀏覽

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學(xué)習(xí)伙伴

公眾號

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號