摘要:
C++语言: Codee#2574401 /*02 对象切片03 此处为传值 注意与传地址相比较04 */05 #include <iostream>06 #include <string>07 using namespace std;08 09 class Pet10 {11 string pname;12 public:13 Pet(const string& name)14 : pname(name)15 {}16 virtual string name() const17 {18 return pname;19 }20 virtual string de 阅读全文
posted @ 2012-03-08 10:46
strorehouse
阅读(212)
评论(0)
推荐(0)
摘要:
C++语言: Codee#2574201 #include <iostream>02 #include <cstdio>03 using namespace std;04 05 class NotEmpty06 {07 08 };09 10 int main()11 {12 cout<<sizeof(NotEmpty)<<endl;13 return 0;14 }15 16 /*17 118 19 Process returned 0 (0x0) execution time : 0.027 s20 Press any key to contin 阅读全文
posted @ 2012-03-08 09:30
strorehouse
阅读(120)
评论(0)
推荐(0)
浙公网安备 33010602011771号