摘要: 修饰普通变量 const int age;==>int const age; 值都不能改变修饰指针 const int *age;==>int const*age; 指针指向的值不能改变,指向的空间可以改变 int * const age; 指针指向的空间不能改变,指向的值可以改变 阅读全文
posted @ 2016-01-05 20:28 爱上咖啡的唐 阅读(132) 评论(0) 推荐(0) 编辑
摘要: 在基本类型时没有差别如typedef int myInt使用和#define int myInt看不出区别特别之处typedef char * String1和#definechar * String2String1 name1和String2 name2使用也看不出区别但是String1 name... 阅读全文
posted @ 2016-01-05 20:09 爱上咖啡的唐 阅读(169) 评论(0) 推荐(0) 编辑
摘要: 1 普通变量 typedef int myInt; 后面就可以用myInt代替int定义变量了,效果相同2 结构体变量 1) Struct Person { int age; char *name; } typedef Struct Person myPe... 阅读全文
posted @ 2016-01-05 20:03 爱上咖啡的唐 阅读(472) 评论(0) 推荐(0) 编辑