摘要: // container.cpp : 定义控制台应用程序的入口点。//#include "stdafx.h"#include#includeusing namespace std;int _tmain(int argc, _TCHAR* argv[]){typedef string *pstring;string a = "abc";//const pstring good = &a; 这一句和下一句的效果是一致的string *const good=&a;string b = "abcs";//good = b;re 阅读全文
posted @ 2013-09-24 03:32 CrazyCode. 阅读(172) 评论(0) 推荐(0) 编辑
摘要: Exmpl.h/////////#pragma once#includeclass Exmpl{public://默认构造函数Exmpl(){std::cout#include#include"Exmpl.h"#include"Employee.h"using namespace std;void fun(Exmpl obj){}void fun2(Exmpl &obj){}Exmpl fun3(){Exmpl obj;return obj;}int _tmain(int argc, _TCHAR* argv[]){//Exmpl a;//这里调 阅读全文
posted @ 2013-09-24 03:27 CrazyCode. 阅读(184) 评论(0) 推荐(0) 编辑
摘要: // container.cpp : 定义控制台应用程序的入口点。//#include "stdafx.h"#include#include#includeusing namespace std;int _tmain(int argc, _TCHAR* argv[]){char ca1[]={'1','2','3'};cout<<sizeof(ca1)/sizeof(char)<<endl;//输出3char ca2[]="123";cout<<sizeof(ca2)/s 阅读全文
posted @ 2013-09-24 03:25 CrazyCode. 阅读(161) 评论(0) 推荐(0) 编辑