上一页 1 2 3 4 5 6 7 8 9 10 ··· 18 下一页
摘要: #include int main(void){ char *p[10]; printf("%d\t%d\n", sizeof(p), sizeof(*p)); return 0;} 阅读全文
posted @ 2015-09-22 15:11 微博和csdn还有你 阅读(127) 评论(0) 推荐(0) 编辑
摘要: #include /*通过回调函数的性质模拟早晨被叫醒的场景注意:闹钟和父母的行为是被抽象的共同的行为是,到一个时间点被触发。*//************************************************************************//* 定义回调函数 ... 阅读全文
posted @ 2015-09-22 09:50 微博和csdn还有你 阅读(165) 评论(0) 推荐(0) 编辑
摘要: #include #define A 0int funcA(int a, int b){ return a + b;}/*把指针作为函数的返回值*/int * funcB(int a, int b){ static int c = A; c = a + b; return &... 阅读全文
posted @ 2015-09-22 09:40 微博和csdn还有你 阅读(176) 评论(0) 推荐(0) 编辑
摘要: #include void funcA(int *p_int_a, int int_b){ *p_int_a = 100; int_b = 200; printf("funcA: *p_int_a = %d, int_b = %d \n", *p_int_a, int_b); ... 阅读全文
posted @ 2015-09-22 09:38 微博和csdn还有你 阅读(126) 评论(0) 推荐(0) 编辑
摘要: #include /*声明一个函数,函数名称的本质就是一个函数指针*/int funcA(int a, int b){ int c = a + b; printf("a = %d, b = %d \n", a, b); return c;}/*声明一个函数指针*//*注意,函数指针... 阅读全文
posted @ 2015-09-22 09:36 微博和csdn还有你 阅读(127) 评论(0) 推荐(0) 编辑
摘要: 指针与函数1、指针与函数的返回值2、指针和函数的参数 函数传参的两种方式:传值和传址如果是传值,在被调函数内部不能改变主调函数变量的值。如果是传址,在被调函数内部可以通过地址来操作外部的变量。3、函数指针指向函数的指针函数名称本身就是一个函数指针。比如:int (*p_func)(int)第一个in... 阅读全文
posted @ 2015-09-22 08:45 微博和csdn还有你 阅读(144) 评论(0) 推荐(0) 编辑
摘要: #include #include #include #define N 10void init_arry(int a[], int n){ int i; srand(time(NULL)); for (i = 0; i a[j+1]) swa... 阅读全文
posted @ 2015-09-21 11:08 微博和csdn还有你 阅读(182) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2015-09-21 09:37 微博和csdn还有你 阅读(111) 评论(0) 推荐(0) 编辑
摘要: #include #include #include #include #include void generate(char computer[]){ int i = 0, j, t; srand(time(NULL)); while (i 0) { putcha... 阅读全文
posted @ 2015-09-21 08:58 微博和csdn还有你 阅读(582) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2015-09-21 08:39 微博和csdn还有你 阅读(152) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 10 ··· 18 下一页