类的运用(一)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 | #include using
namespace
std;
class
Dog{ public
: Dog(
int
Age,
int
Weight);
//构造函数 Dog(Dog&gou);
//复制构造函数 int
setAge(
int
Age);
int
setWeight(
int
Weight);
int
getAge();
int
getWeight();
~Dog(){ cout<<
"~Dog"
< |
【类的运用(一)】
本文转自 pangfc 51CTO博客,原文链接:http://blog.51cto.com/983836259/1338324,如需转载请自行联系原作者
推荐阅读
- 热闹中的孤独
- JAVA(抽象类与接口的区别&重载与重写&内存泄漏)
- 放屁有这三个特征的,请注意啦!这说明你的身体毒素太多
- 一个人的旅行,三亚
- 布丽吉特,人生绝对的赢家
- 慢慢的美丽
- 尽力
- 一个小故事,我的思考。
- 家乡的那条小河
- 《真与假的困惑》???|《真与假的困惑》??? ——致良知是一种伟大的力量