摘要: 1、指针 指针本身存储变量的地址,当*与之配合使用时,*与指针的整体可以代表变量本身。 如 1: int a = 0; 2: int *b = &a; 3: (*b) = 2; //相当于 a = 2;那么在声明时特别注意 1: //*与指针结合代表一个变量(形如*pointer ) 2: int* a,b,c; //第一段声明,此处不是声明了三个指针 3: int b,c,... 阅读全文
posted @ 2011-12-02 20:45 martin@dlut 阅读(462) 评论(0) 推荐(0) 编辑
摘要: 1 #include <stdio.h> 2 #include <stdlib.h> 3 /* 4 int a=0; /*此行注释开头的注释符被当做普通字符,此行注释结尾的注释符被看做是注释的结束*/ 5 6 */ /* 此行开始的表示注释结束的符号由于无法匹配报错。 */ 7 8 int main() 9 {10 printf("he\n");11 ret... 阅读全文
posted @ 2011-11-29 18:36 martin@dlut 阅读(474) 评论(0) 推荐(0) 编辑
摘要: #include <stdio.h>int main(int argc,char * argv[]) { printf("hello world!\n"); return 0;} 阅读全文
posted @ 2011-11-26 12:46 martin@dlut 阅读(183) 评论(0) 推荐(0) 编辑