2015年5月28日

引用高级

摘要: 1 /* 引用高级 */ 2 3 /* 引用一维数组 */ 4 #include 5 #include 6 7 void main() 8 { 9 int a[10] = {1,2,3,4,5,6,7,8,9,10}; 10 int(& ra)[10](a);... 阅读全文

posted @ 2015-05-28 21:39 Dragon-wuxl 阅读(241) 评论(0) 推荐(0)

ccpp的enum

摘要: 1 /* enum */ 2 3 // c 语言 4 5 #include 6 7 enum color{red=11,yellow,green,white}; 8 9 void main()10 {11 enum color c1;12 cl = red;// 不注重数... 阅读全文

posted @ 2015-05-28 09:29 Dragon-wuxl 阅读(145) 评论(0) 推荐(0)

bool类型

摘要: 1 /* bool */ 2 3 #include 4 5 int main() 6 { 7 bool b1 = 1 && 1 || 2 || -1 && 0; 8 std::cout << typeid(b1).name() << std::endl; 9 std::... 阅读全文

posted @ 2015-05-28 09:09 Dragon-wuxl 阅读(135) 评论(0) 推荐(0)

auto自动类型

摘要: 1 /* auto自动类型 */ 2 3 #include 4 5 int main() 6 { 7 double db = 10.9; 8 double *pdb = &db; 9 auto num = pdb;// 通用传入接口10 std::cout <<... 阅读全文

posted @ 2015-05-28 08:59 Dragon-wuxl 阅读(168) 评论(0) 推荐(0)

导航