1. constructor overloading
2. Class繼承後的constructor 跟 destructor(刪除順序)
http://openhome.cc/Gossip/CppGossip/ConDesAfterInheritance.html
3. difference between overloading & overriding
http://stackoverflow.com/questions/429125/override-and-overload-in-c
4. Type casting
http://hscripts.com/tutorials/cpp/type-casting.php
5. for(...; ....; ++x) 比 for(...; ....; x++) 有效率
6. scanf, fscanf in C language do not accept(recognize) string type(C++)
7.for 迴圈時 pointer *(A+x) 比 A[x] 有效率
8. {intx....} 大括弧可以限制變數生命週期
9. new 空間完都要檢查,在記憶體不足的電腦裡容易抓不到空間
int* p = new int[1000]; if(!p){printf"no memory!!"}
10. register 關鍵字用來讓變數存放於 CPU register ,加速存取記憶體。
Problem:
1. what is a virtual funciton? (seems to be used in overriding)
2. what is the difference between define funciton & inline function?
3. how to write an exception handler?
沒有留言:
張貼留言