![](https://img-blog.csdnimg.cn/20201014180756925.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
c
gl_ding
这个作者很懒,什么都没留下…
展开
-
关于scanf()的缓冲区问题
奇怪的死循环!!副以下程序:#includemain(){int i;do{printf("*");scanf("%d",&i);}while(1);}这个程序非常的简单.粗看上去没有什么,功能就是每打印一个星号后等待用户输入一个整形得值,但问题接种而来,用户一但输入的是数字外的各种字符,立刻造成死循环.单步执行也无法跳出.但作为scanf这样的控制流函数,无论我的输入是否正确转载 2009-09-19 21:46:00 · 1244 阅读 · 1 评论 -
C/C++ 笔试、面试题目大汇总
http://blog.csdn.net/wfwd/archive/2006/05/30/763664.aspx转载 2009-09-25 18:34:00 · 344 阅读 · 0 评论 -
指针
原则:给没分配使用权的地址空间赋值或修改值毕出现段错误。 1.函数中直接使用字符串,如 char *str; str = "adsf". "adsf"返回的的地址应该在栈空间里。 随函数消失,此空间的使用权消失。如:typdef struct _stu{ char *a;}stu;void fuc(stu *stu){ stu->a = "shit原创 2009-10-20 17:23:00 · 409 阅读 · 0 评论 -
C++著名程序库
http://blog.chinaunix.net/u3/95562/showart.php?id=2078430转载 2009-10-29 17:40:00 · 452 阅读 · 0 评论 -
更改配置文件: glib的函数实现key-data
http://linux.chinaunix.net/techdoc/develop/2008/06/19/1012039.shtml转载 2009-11-23 20:07:00 · 486 阅读 · 0 评论