<?xml version="1.0" encoding="gb2312"?>

<!-- RSS generated by oioj.net on 4/16/2004 ; 感谢LeXRus提供 RSS 2.0 文档; 此文件可自由使用，但请保留此行信息 --> 
<!-- Source download URL: http://blogger.org.cn/blog/rss2.asp       -->
<rss version="2.0">

<channel>
<title>漫漫编程路，感悟C精深</title>
<link>http://blogger.org.cn/blog/blog.asp?name=jwzxgo</link>
<description>jwzxgo的博客</description>
<copyright>blogger.org.cn</copyright>
<generator>W3CHINA Blog</generator>
<webMaster>webmaster@blogger.org.cn</webMaster>
<item>
<title><![CDATA[I HAD CHOSE MY FUTURE]]></title>
<link>http://blogger.org.cn/blog/more.asp?name=jwzxgo&amp;id=29675</link>
<author>jwzxgo</author>
<pubDate>2007/11/14 18:20:55</pubDate>
<description><![CDATA[<P><FONT face="Arial Black" size=5>Coding is a terrible thing, while algorithms is really interesting and useful. But the important part of it is not on coding, but thinking, in other word, logic and math. Computer should be the tool for research, rather than the aim. Besides, it's becoming more and more terrible for its man-made complexity, uncertain and business oriented. It can no longer be a simple and easy way to carry my idea, as I had treat it before. The most powerful way I have ever met, presently, is math. Computer will surely be more and more smart, although, I do not like that. But before this horrible situation occurred. There must be several steps of revolution in the mode of designing on both software and hardware. I don't want to be among revolutionees ,but one of revolutioners. So I choose my future to do research in the area of The Quantum Theory , which have the possible to cause in the revolution in a day far from imagination. <BR>Thanks to Algorithms and Mathematic Analysis pulling me from the quagmire, attracting in surface, to the solid earth. </FONT><A id=blog_recent_245862928 title="I HAD CHOSE MY FUTURE" href="http://blog.xiaonei.com/GetEntry.do?id=245862928&amp;owner=223396518"><FONT color=#3b5998></FONT></A></P>]]></description>
</item><item>
<title><![CDATA[2007年10月5日 学习报告]]></title>
<link>http://blogger.org.cn/blog/more.asp?name=jwzxgo&amp;id=28500</link>
<author>jwzxgo</author>
<pubDate>2007/10/5 21:24:38</pubDate>
<description><![CDATA[<meta http-equiv="Content-Type" content="text/html; charset=gb2312"><title>无标题文档</title><style type="text/css"><!--.STYLE2 {&#160;&#160; &#160;font-size: 36px;&#160;&#160; &#160;color: #3399FF;}.STYLE3 {&#160;&#160; &#160;font-size: 16px;&#160;&#160; &#160;font-family: "宋体";&#160;&#160; &#160;color: #3366FF;}--></style><h1 class="head STYLE2" align="center">http://blog.ccidnet.com/blog-htm-do-showone-uid-44554-type-blog-itemid-193094.html<br></h1><h1 class="head STYLE2" align="center">学习报告</h1><table border="0" height="54" width="100%">&nbsp; <tbody><tr>&nbsp;&nbsp;&nbsp; <td>姓名：王铁震</td>&nbsp;&nbsp;&nbsp; <td>时间：2007年10月5日20:51:39</td>&nbsp; </tr></tbody></table><h2 align="left">提议：</h2><blockquote>&nbsp; <p align="left">无。</p></blockquote><h2 align="left">上周主要工作：</h2><ul>&nbsp; <li>学习数据结构，（详见下方）。</li>&nbsp; <li>学会使用、配置了UEStudio这种很强大的编辑器。</li></ul><h2>存在问题及拟采取方案：</h2><blockquote>&nbsp; <p>无。</p></blockquote><h2>下周计划：</h2><ol>&nbsp; <li>继续学习数据结构。</li></ol><h2>上周工作成果介绍：</h2><blockquote>&nbsp; <p>程序：（见附件）。</p>&nbsp; <p>#include"head_list.h"<br>&nbsp; #include"list.c"</p>&nbsp; <p>这两个文件是线性链表的完整实现。具体有：</p>&nbsp; <p align="left">extern status list_add( );<br>&nbsp;&nbsp;&nbsp; extern status list_empty( );<br>&nbsp;&nbsp;&nbsp; extern status list_init();<br>&nbsp;&nbsp;&nbsp; extern status list_insert();<br>&nbsp;&nbsp;&nbsp; extern status list_del();<br>&nbsp;&nbsp;&nbsp; extern status list_destory();<br>&nbsp;&nbsp;&nbsp; extern status list_visit();<br>&nbsp;&nbsp;&nbsp; extern status list_visit_reverse();<br>&nbsp;&nbsp;&nbsp; extern length_type list_length();<br>&nbsp;&nbsp;&nbsp; extern data_pointer list_get();<br>&nbsp; extern status list_swap();</p>&nbsp; <p>#include "josephus.c"<br>&nbsp; #include "josephus_array.c"<br>&nbsp; #include "cal_time.c"</p>&nbsp; <p>这三个文件实现了josephus问题。并比较了时间消耗的程度。</p>&nbsp; <p>#include "btree.c"</p>&nbsp; <p>这个文件实现了二插排序树的基本操作，包括：</p>&nbsp; <p>extern tpointer btree_find(tpointer root, num_size num);<br>&nbsp;&nbsp;&nbsp; extern int btree_other_print1(tpointer root);<br>&nbsp;&nbsp;&nbsp; extern int btree_del_value(tpointer *proot, num_size num);<br>&nbsp;&nbsp;&nbsp; extern int btree_del(tpointer *proot);<br>&nbsp;&nbsp;&nbsp; extern int btree_visit(tpointer root, int f(), int style);<br>&nbsp;&nbsp;&nbsp; extern int btree_destory(tpointer root);<br>&nbsp;&nbsp;&nbsp; extern int&nbsp; btree_add(tpointer* root, num_size data);<br>&nbsp;&nbsp;&nbsp; extern void rand_begin(num_size num);<br>&nbsp;&nbsp;&nbsp; extern num_size rand_range(num_size max);<br>&nbsp; extern int btree(void);</p>&nbsp; <p>&nbsp;</p>&nbsp; <p class="head STYLE2 STYLE3" align="left">&nbsp;&nbsp;&nbsp; &nbsp;</p></blockquote>]]></description>
</item><item>
<title><![CDATA[feof 与 文件读写导致文件增大问题]]></title>
<link>http://blogger.org.cn/blog/more.asp?name=jwzxgo&amp;id=28270</link>
<author>jwzxgo</author>
<pubDate>2007/9/23 12:25:56</pubDate>
<description><![CDATA[
<div class="Section0">
<h1 style="text-align: justify;"><span style="font-weight: bold; font-size: 22pt; font-family: '宋体';"><font face="宋体">关于FEOF函数的问题</font></span><span style="font-weight: bold; font-size: 22pt; font-family: '宋体';"><o:p></o:p></span>
</h1><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">-1<font face="宋体">是C中流式文件函数feof()返回的值，表示文件结束，但不说明实际的文件结束符是-1。&nbsp;&nbsp;&nbsp;</font></span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;&nbsp;<font face="宋体">任何文件都没有非要不可的、强行规定的文件结束符。二进制文件是绝对没有规定的，文本文件有一个并非必须使用的文件结束符0x26，但行结束符是必须遵守的\t\n或者\0x0d\0x0a，否则就不为文本文件了。&nbsp;&nbsp;&nbsp;</font></span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;&nbsp;<font face="宋体">至于smiling1982&nbsp;&nbsp;&nbsp;(smiling)反映的情况不是文件结束符造成的，而是C流式文件机制产生的，fread()函数每次执行后，都要移动文件指针到下一个未读取的字符处，并保留一个是否成功读取的标记，而feof()只是如实返回这个标记。请看下面的二进制文件内容：&nbsp;&nbsp;&nbsp;</font></span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;xxxxxxxxyyyyyyyy&nbsp;&nbsp;&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;&nbsp;8<font face="宋体">个x和8个y分别为一条记录，文件打开时，文件指针指向0，即第一个x，读取标记初始化为0；读第一条记录，指针移动到8，即第一个y，读取标记=0；读第二条记录，文件指针移动到16，即文件结束的地方，读取标记=0。由于feof()每次都是在fread()之后返回这个标记，所以再次调用!feof()必然为真，而事实上文件已经结束，直至再次读失败，读取标记=-1时已经迟了，我们已经read了三次。所以可以这样写：&nbsp;&nbsp;&nbsp;</font></span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;&nbsp;&nbsp;&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;&nbsp;&nbsp;&nbsp;while(&nbsp;&nbsp;&nbsp;1&nbsp;&nbsp;&nbsp;)&nbsp;&nbsp;&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;&nbsp;{</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-indent: 21pt; text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">c&nbsp;&nbsp;&nbsp;=&nbsp;&nbsp;&nbsp;fgetc(&nbsp;&nbsp;&nbsp;fp&nbsp;&nbsp;&nbsp;);&nbsp;&nbsp;&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-indent: 21pt; text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">if(feof(fp))&nbsp;&nbsp;&nbsp;break;&nbsp;&nbsp;&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-indent: 21pt; text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">printf("\n%d",&nbsp;&nbsp;&nbsp;c);&nbsp;&nbsp;&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;&nbsp;}&nbsp;&nbsp;&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;&nbsp;&nbsp;<font face="宋体">引自：http://topic.csdn.net/t/20021210/10/1246308.html&nbsp;maozefa（阿发伯）</font></span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="0" style="text-align: justify;"><span style="font-size: 10.5pt; font-family: '宋体';"><o:p></o:p></span></p><p class="0" style="text-align: justify;"><span style="font-size: 10.5pt; font-family: '宋体';"><font face="宋体">这就可以很好的解释，为什么正常的文件读写</font></span><span style="font-size: 10.5pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">while(&nbsp;!feof(fp)&nbsp;){</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">c&nbsp;=&nbsp;fgetc(fp);</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">fputc(c,&nbsp;fpout);</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">i++;</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">}</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="0" style="text-align: justify;"><span style="font-size: 10.5pt; font-family: '宋体';"><font face="宋体">会出现输出文件会比输入文件末尾多出来一个FF，正确的做法应该是：</font></span><span style="font-size: 10.5pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">while(&nbsp;!feof(fp)&nbsp;){</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">c&nbsp;=&nbsp;fgetc(fp);</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">if(feof(fp))</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">break;</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">fputc(c,&nbsp;fpout);</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">i++;</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="15" style="text-align: justify;"><span style="font-size: 9pt; font-family: '宋体';">&nbsp;</span><span style="font-size: 9pt; font-family: '宋体';">}</span><span style="font-size: 9pt; font-family: '宋体';"><o:p></o:p></span></p><p class="0" style="text-align: justify;"><span style="font-size: 10.5pt; font-family: '宋体';"><font face="宋体">因为feof()只会返回上一次fgetc()的成败与否。</font></span><span style="font-size: 10.5pt; font-family: '宋体';"><o:p></o:p></span></p><p class="0" style="text-align: justify;"><span style="font-size: 10.5pt; font-family: '宋体';"><o:p><br></o:p></span></p>
</div>]]></description>
</item><item>
<title><![CDATA[Why I reinstsall windows again.]]></title>
<link>http://blogger.org.cn/blog/more.asp?name=jwzxgo&amp;id=28255</link>
<author>jwzxgo</author>
<pubDate>2007/9/22 13:58:29</pubDate>
<description><![CDATA[After living in Linux or say trying Linux for several days,I was no longer hites Windows as strong as before.As an operating system,Windows has his advangtage and disadvantage.But to me,the reason why I changed my idea,that I deleted Windows and only use my personal computer in Linux,wasn't on there.The most basic one is that I can not find enough easy going softwares.As a greener,I don't have that much energy and ability to learn some strange ones,although most of them are powerful and free of charge, but the books or informations of them are too hard to find and too hard to study,besides most of which are online ones. I want to begin my work or learn the basic information quickly, so I perfer to choose to learn some techniques or software environments of some widely used ones.I think if someone have had some basic knowledge of the system, or some even advanced knowledge, he or she may find it's a good idea to use the GNU system.If a man only want to begin a new area of his study experience, he/she had better start it by learning some easy reached books, ranther than using some ones with few informations only for being effected by some higher leveled professiors.So ,I think learning Linux is usful, but it isn't the most improtant one just now. If you want to improve your level, I strongly advise you to start from the softwares that can easily run and can be easily learnt.
It can be a great challenge for the readers to understand my real means, not for my thought is deep, but for my poor english.Thank you for you bearing!]]></description>
</item>
</channel>
</rss>