2016年8月16日
该文被密码保护。 阅读全文
posted @ 2016-08-16 16:25 miracley 阅读(1) 评论(0) 推荐(0) 编辑
  2016年7月3日
摘要: 公司需要白底的图片做工卡,但是我只有红底的,于是p了一下,效果如图: >, 发现身体边缘有很明显的红色的边界线。这里思考后,发现红色边缘的原因是由于魔棒工具选择的边缘太粗,如图所示: 如图所示,可以很清晰的看到边缘和蚁行线之间有很大的缝隙,因此在魔棒工具选取边界的时候就加大边界像素,如图,点击调整边 阅读全文
posted @ 2016-07-03 19:01 miracley 阅读(1811) 评论(0) 推荐(0) 编辑
  2016年6月27日
摘要: 这里能正常输出 -bash-3.2$ ./a.out 1 b1 b1 b-bash-3.2$ 若把结构体的数据类型改变: 结果也能正常显示 -bash-3.2$ ./a.out 1 b1 b1 b-bash-3.2$ 阅读全文
posted @ 2016-06-27 17:55 miracley 阅读(1316) 评论(0) 推荐(0) 编辑
摘要: assert在C语言中的作用是: assert中的表达式为false,则终止程序继续执行。 阅读全文
posted @ 2016-06-27 11:33 miracley 阅读(105) 评论(0) 推荐(0) 编辑
摘要: 在代码中,我看到了类似这样的情况: typedf unsigned char BYTE; typedf BTYE * PBYTE; void foo(PBYTE A) { printf("%c\n",A); } int main(int args,char *arg[]) { BYTE *A='W' 阅读全文
posted @ 2016-06-27 09:50 miracley 阅读(173) 评论(0) 推荐(0) 编辑
  2016年6月17日
摘要: 原型为:snprintf(char *str, size_t size, const char *format, ...) 将可变个参数(...)按照format格式化成字符串,然后将其复制到str中 (2) 如果格式化后的字符串长度 >= size,则只将其中的(size-1)个字符复制到str中 阅读全文
posted @ 2016-06-17 11:37 miracley 阅读(157) 评论(0) 推荐(0) 编辑
  2016年6月14日
摘要: #include<stdio.h> int f1(int x,int y)//返回大 { printf("this is f1\t\n"); return x>y?x:y; } int f3(int x,int y)//返回小 { printf("this is f3\t\n"); return x 阅读全文
posted @ 2016-06-14 11:15 miracley 阅读(130) 评论(0) 推荐(0) 编辑
摘要: #include<stdio.h>#include<string.h> int main(int argc,char *arg[]){ char alls[4]={'a','b','c'}; printf("%s\n",alls);} c语言中,如果想直接输出char数组中的所用内容,直接输出数组名 阅读全文
posted @ 2016-06-14 10:20 miracley 阅读(118) 评论(0) 推荐(0) 编辑
摘要: #include<stdio.h> typedef struct A { int a; char b; } foo;int f2(){ printf("this is f2\n"); return 2;} void f3(int x,char y){ printf("this is f3 + %d\ 阅读全文
posted @ 2016-06-14 10:01 miracley 阅读(872) 评论(0) 推荐(0) 编辑
  2016年6月12日
摘要: memcpy(*,*,int) param1:目标(指针类型) param2:源(指针类型) param3:复制长度 #include<stdio.h>#include <stdlib.h>#include <string.h> int main(void){ char *p1="ABCD"; ch 阅读全文
posted @ 2016-06-12 16:54 miracley 阅读(91) 评论(0) 推荐(0) 编辑