<?xml version="1.0" encoding="utf-8" ?><rss version="2.0"><channel><title><![CDATA[prettyinsight的专栏]]></title><description><![CDATA[]]></description><link>https://blog.youkuaiyun.com/prettyinsight</link><language>zh-cn</language><generator>https://blog.youkuaiyun.com/</generator><copyright><![CDATA[Copyright &copy; prettyinsight]]></copyright><item><title><![CDATA[如何让计算机计算四则运算表达式[第一篇]]]></title><link>https://blog.youkuaiyun.com/prettyinsight/article/details/5424109</link><guid>https://blog.youkuaiyun.com/prettyinsight/article/details/5424109</guid><author>prettyinsight</author><pubDate>Sun, 28 Mar 2010 09:24:00 +0800</pubDate><description><![CDATA[      从今天开始，我要发表些一系列文章。讨论关于如何编程实现加减乘除四则运算的解析和计算。我现在所掌握的一共有三种方法。      第一种方法称为递归下降。通过调用一些相互递归的函数来解析表达式。不需要任何前提知识。      第二种方法首先建立抽象语法树，然后再遍历语法树，把中缀表达式变成后缀表达式，然后再计算。需要一点编译原理的知识。      第三种方法首先建立抽象语法树，]]></description><category></category></item><item><title><![CDATA[一个SLR,LR,LALR语法分析器]]></title><link>https://blog.youkuaiyun.com/prettyinsight/article/details/5410928</link><guid>https://blog.youkuaiyun.com/prettyinsight/article/details/5410928</guid><author>prettyinsight</author><pubDate>Wed, 24 Mar 2010 10:54:00 +0800</pubDate><description><![CDATA[这些天我编写了一些语法分析器，它能够分析符合SLR，LR，LALR规范的语句。所有的类都放在syntexparse包中。算法来自与龙书。下面是一些用法。Symbol类表示文法中的终结符和非终结符。构造函数的第一个参数为符号名称，类型为String。第二个参数表示该符号是终结符还是非终结符，类型为boolean。用法：对于推导规则E->E+T中文法符号E,+,T可以这样来表示非终结符E：Sy]]></description><category></category></item><item><title><![CDATA[8 Puzzle/8 数码问题]]></title><link>https://blog.youkuaiyun.com/prettyinsight/article/details/5247744</link><guid>https://blog.youkuaiyun.com/prettyinsight/article/details/5247744</guid><author>prettyinsight</author><pubDate>Sat, 23 Jan 2010 10:54:00 +0800</pubDate><description><![CDATA[                                                          这些天一直在研究8数码问题，用C++实现了A*。并且用了C++的模板使得它也能够处理15数码的问题。但是15数码的问题的难度超乎了我的想象。A*不管用了。一个更好方案是使用IDA*算法。前几天看了篇论文，发现了一个增强版的IDA*算法。所以决定使用这个威力加强版IDA*算法来处理]]></description><category></category></item><item><title><![CDATA[Triple Des算法]]></title><link>https://blog.youkuaiyun.com/prettyinsight/article/details/5168657</link><guid>https://blog.youkuaiyun.com/prettyinsight/article/details/5168657</guid><author>prettyinsight</author><pubDate>Sun, 10 Jan 2010 11:21:00 +0800</pubDate><description><![CDATA[参考资料：http://www.tropsoft.com/strongenc/des3.htm 自己用c写的： /*tripledes.c  Triple Des算法*/   #include#define ENCRYPTION 1#define DECRYPTION 0typedef unsigned char byte;/*参数和des一样，]]></description><category></category></item><item><title><![CDATA[DES算法]]></title><link>https://blog.youkuaiyun.com/prettyinsight/article/details/5163808</link><guid>https://blog.youkuaiyun.com/prettyinsight/article/details/5163808</guid><author>prettyinsight</author><pubDate>Sat, 09 Jan 2010 11:39:00 +0800</pubDate><description><![CDATA[参考资料：1）非常详细的算法过程http://www.tropsoft.com/strongenc/des.htm2）用javascript写的DES，显示算法每一步的结果，对调试算法很有帮助http://people.eku.edu/styere/Encrypt/JS-DES.html自己用C写的算法： /* DES算法   des.c */ #include]]></description><category></category></item><item><title><![CDATA[产生质数的迭代器]]></title><link>https://blog.youkuaiyun.com/prettyinsight/article/details/5075437</link><guid>https://blog.youkuaiyun.com/prettyinsight/article/details/5075437</guid><author>prettyinsight</author><pubDate>Fri, 25 Dec 2009 14:55:00 +0800</pubDate><description><![CDATA[      这篇文章介绍两种用python编写质数迭代器的方法。      第一种方法非常简单： def genprime():	yield 2	for n in countodd(1):		if isprime(n):			yield n         这个方法的思想是除了2之外，在所有奇数中判断是否为质数。countodd是一个奇数迭代器。可以这样来定义：de]]></description><category></category></item><item><title><![CDATA[Google Treasure Hunt 2008 Question:Robot]]></title><link>https://blog.youkuaiyun.com/prettyinsight/article/details/5045782</link><guid>https://blog.youkuaiyun.com/prettyinsight/article/details/5045782</guid><author>prettyinsight</author><pubDate>Mon, 21 Dec 2009 09:39:00 +0800</pubDate><description><![CDATA[问题是这样的：A robot is located at the top-left corner of a 66 x 49 grid (marked Start in the diagram below).The robot can only move either down or right at any point in time. The robot is trying to r]]></description><category></category></item><item><title><![CDATA[用python解决 Google Treasure Hunt 2008 Question:Primes]]></title><link>https://blog.youkuaiyun.com/prettyinsight/article/details/5038040</link><guid>https://blog.youkuaiyun.com/prettyinsight/article/details/5038040</guid><author>prettyinsight</author><pubDate>Sat, 19 Dec 2009 13:56:00 +0800</pubDate><description><![CDATA[问题：Find the smallest number that can be expressed as                           the sum of 7 consecutive prime numbers,                                           the sum of 21 consecutive prime numbe]]></description><category></category></item><item><title><![CDATA[Google Treasure Hunt 2008 Question:Primes]]></title><link>https://blog.youkuaiyun.com/prettyinsight/article/details/5037013</link><guid>https://blog.youkuaiyun.com/prettyinsight/article/details/5037013</guid><author>prettyinsight</author><pubDate>Sat, 19 Dec 2009 11:31:00 +0800</pubDate><description><![CDATA[这个问题的题目是：Find the smallest number that can be expressed as                           the sum of 7 consecutive prime numbers,                                           the sum of 21 consecutive prime]]></description><category></category></item></channel></rss>