摘要: 函数next_permutation()是按照字典序产生排列的,并且是从数组中当前的字典序开始依次增大直至到最大字典序。 就是按照ascii码表的顺序,值大的在后面。 以下转载自http://blog.sina.com.cn/s/blog_9f7ea4390101101u.html 这是一个求一个排 阅读全文
posted @ 2017-04-03 09:15 MetalTree 阅读(536) 评论(0) 推荐(0)
摘要: 以下转载自:http://blog.sina.com.cn/s/blog_4a033b090100zdsd.html 下午做最长公共子序列的时候遇到的问题,问了felix后恍然大悟...看代码 #include <stdio.h> int main() { int a[1000000];//局部变量 阅读全文
posted @ 2017-04-02 09:25 MetalTree 阅读(615) 评论(0) 推荐(0)
摘要: 请结合具体例子看 必要时将每一步具体数据写下 注明: 代码里数据有两个主要类型, 一个是位置pos数组,相当于n个盒子。相关的是step,是位置的移动。 一个是要排列的n个数字 i(1-n)。相关的是 i 的标记tick,是针对数字而不是位置的。 阅读全文
posted @ 2017-03-11 10:15 MetalTree 阅读(1363) 评论(0) 推荐(0)
摘要: application不能运行,console显示 The connection to adb is down, and a severe error has occured. You must restart adb and Eclipse. Please ensure that adb is c 阅读全文
posted @ 2016-09-13 17:28 MetalTree 阅读(1222) 评论(0) 推荐(0)