上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 16 下一页
摘要: //extern外部函数:定义的函数能被本文件访问和其他文件访问,默认情况下所有函数都是外部函数1>不允许同名 2>默认都是所有函数都是外部 //static内部函数:定义的函数只能被本文件访问,其他文件不能访问 1>允许同名 extern void test(){ printf("外部函数,默认情 阅读全文
posted @ 2016-03-10 14:02 谢小锋 阅读(158) 评论(0) 推荐(0) 编辑
摘要: 结构体 typedef struct{ char *Sname; int age;}structName; 枚举 typedef enum{ oneEnum=1, twoEnum,}enumName; 函数指针宏定义 typedef int (*p)(int ,int);// int (*p)(in 阅读全文
posted @ 2016-03-09 16:45 谢小锋 阅读(146) 评论(0) 推荐(0) 编辑
摘要: 预编译指令的作用域:从编写指令的那一行开始,一直到文件结尾 宏名一般用大写 或K开头其他小写 #define name 23 //局部宏只对下文有效 printf("%d",nameString);//错误❌ int arr[name]={23,23,4,34}; #undef name print 阅读全文
posted @ 2016-03-08 17:07 谢小锋 阅读(171) 评论(0) 推荐(0) 编辑
摘要: 必须条件:99$(没这个就不用再往下看了)我的系统是10.5.7 不同版本的系统,可能有点小小的区别首先登录到http://developer.apple.com/iphone/index.action如果已经购买了99$, 登录进去后会看到如下地方(图1) 点进去会看到如下界面(图2) 这里我要提 阅读全文
posted @ 2016-03-04 10:20 谢小锋 阅读(257) 评论(0) 推荐(0) 编辑
摘要: 1.快速打开 快速打开(Open Quickly)命令在Xcode的File菜单中,当然,用快捷键Command+Shift+O会更方便一些。这个命令可以开启一个小窗格用来快速搜索浏览文件、类、算法以及函数等。 这个命令每天都为我节省了巨多的时间,如果你还没有试过快速打开的命令,强烈推荐你试一试。 阅读全文
posted @ 2016-03-04 10:14 谢小锋 阅读(452) 评论(0) 推荐(0) 编辑
摘要: 结构体 结构体所占据的存空间是成员变了最大的存储变量的倍数 struct person{ int age; double height; char * name; }; struct person per={.age=12.12,.name="zefeng",.height=23}; per.nam 阅读全文
posted @ 2016-03-03 15:57 谢小锋 阅读(403) 评论(0) 推荐(0) 编辑
摘要: int * p; //p指向int类型的数据的指针 (存放int类型内存地址的内存) int pp=23; p=&pp; *p () printf("p===%d",*p); 指向指针的指针 int o=22; int *q=&o; int **qq=&q; **qq=32; printf("o== 阅读全文
posted @ 2016-03-02 14:42 谢小锋 阅读(137) 评论(0) 推荐(0) 编辑
摘要: int arr[];错误 int arr[23]; arr={23,23}错误(只有在定义数组时同时初始化) int count =3; int arr[count] ={23,23,23}错误 (必须为常量)如果想定义数组的同时初始化,数组个数必须是常量 数组名就是数字的地址 字符串   \0 的 阅读全文
posted @ 2016-03-01 21:06 谢小锋 阅读(156) 评论(0) 推荐(0) 编辑
摘要: int numeber=1010; printf("%d\n",numeber); int numeber1=0b1100; printf("二进制 0b1010=%d\n",numeber1); int numeber2=014; printf("八进制 010=%d\n",numeber2); 阅读全文
posted @ 2016-02-28 19:17 谢小锋 阅读(179) 评论(0) 推荐(0) 编辑
摘要: include 倒入头文件中所有文件 系统自带<> 自定义 "" 相对路径 名称/名称/....文件名 绝对路径 /名称/名称/....文件名 阅读全文
posted @ 2016-02-28 17:18 谢小锋 阅读(197) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 16 下一页