第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

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

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

VS2015報(bào)兩個(gè)錯(cuò)誤但不顯示錯(cuò)誤內(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í)例化對(duì)象*stu student *stu = new student; // 更改對(duì)象的數(shù)據(jù)成員為“慕課網(wǎng)” stu-> setName( "慕課網(wǎng)"); // 打印對(duì)象的數(shù)據(jù)成員 cout << stu->getName() << endl; delete stu; stu = NULL; return 0;}
查看完整描述

1 回答

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

添加回答

舉報(bào)

0/150
提交
取消
微信客服

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

幫助反饋 APP下載

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

公眾號(hào)

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