3 like 0 dislike
230 views

根據程式碼註解的說明,完成以下類別宣告的架構:

     class CMouse { // 定義 CMouse 類別

         $1 :       // 設定以下為私有區塊

           int *ix;

         $2 :       // 設定以下為公有區塊

               CMouse();      // 建構元的原型宣告

               ~CMouse(){ delete ix;  }     // 解構元的定義

               friend GetIx();              // 友誼函式函式 GetIx 的原型宣告

     };

       CMouse::CMouse() {       // 建構元的定義

           ix = new int; ix = 1;

     }

 

參考書籍:旗標無痛學習教本

[Normal] Fill in the blank - asked in Introduction to Computer Programming I (C) by (20.9k points)
ID: 21939 - Available when: Unlimited - Due to: Unlimited
| 230 views
Welcome to Peer-Interaction Programming Learning System (PIPLS) LTLab, National DongHwa University
English 中文 Tiếng Việt
IP:172.69.6.149
©2016-2024

Related questions

3 like 0 dislike
0 answers
[Normal] Fill in the blank - asked Feb 19, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
ID: 21940 - Available when: Unlimited - Due to: Unlimited
| 214 views
3 like 0 dislike
0 answers
[Normal] Fill in the blank - asked Feb 11, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
ID: 21907 - Available when: Unlimited - Due to: Unlimited
| 203 views
4 like 0 dislike
0 answers
[Normal] Fill in the blank - asked Feb 11, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
ID: 21894 - Available when: Unlimited - Due to: Unlimited
| 211 views
3 like 0 dislike
0 answers
[Normal] Fill in the blank - asked Feb 6, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
ID: 21856 - Available when: Unlimited - Due to: Unlimited
| 208 views
3 like 0 dislike
0 answers
[Normal] Fill in the blank - asked Feb 6, 2017 in Introduction to Computer Programming I (C) by The Contributor (20.9k points)
ID: 21855 - Available when: Unlimited - Due to: Unlimited
| 221 views
12,783 questions
183,443 answers
172,219 comments
4,824 users