摘要: class MyClass{ int value;public: MyClass(int i=10) { value = i; cout << "Constructor called." << endl; } MyClass( MyClass& p) { p.value = 11; value = 阅读全文
posted @ 2016-05-04 18:37 huninglei 阅读(206) 评论(0) 推荐(0) 编辑
摘要: class Room{ int room_no; double length; double width;public: Room(int the_room_no, double the_length, double the_width) :room_no(the_room_no), length( 阅读全文
posted @ 2016-05-04 13:32 huninglei 阅读(170) 评论(0) 推荐(0) 编辑