Monthly Archives: August 2010

股市黑天鹅

http://blog.sina.com.cn/s/blog_49b6b2f901009yeh.html

Posted in 投资 | Leave a comment

POJ 1836 —— Alignment

给出系列数字,要求求出一个最长串,使得任意一个数字都不在两个大于等于它的数字中间。 LIS 从前往后跑一遍,然后从后往前跑一遍。最后枚举。

Posted in POJ | Tagged , | Leave a comment

POJ 1006 —— Biorhythms

23*x + p = 28*y + e = 33*z + i = d + A 求一个最小的 A。 http://hi.baidu.com/lewutian/blog/item/95421b82fab6e49bf703a67d.html http://tiandiwuyong1989.blog.163.com/blog/static/122572981200962121733/ http://zh.wikipedia.org/zh-cn/%E4%B8%AD%E5%9B%BD%E5%89%A9%E4%BD%99%E5%AE%9A%E7%90%86

Posted in POJ | Tagged , | Leave a comment

最长递增子序列 LIS

http://blog.csdn.net/logic_nut/archive/2009/09/09/4536779.aspx http://hi.baidu.com/sunshine_0316/blog/item/2f27144e646ebe30afc3ab8d.html http://blog.csdn.net/AskMyself/archive/2005/01/17/256793.aspx http://blog.csdn.net/designer_/archive/2010/04/08/5457836.aspx http://blog.csdn.net/china8848/archive/2008/01/03/2011734.aspx

Posted in 数据结构与算法 | Tagged | Leave a comment

POJ 2195 —— Going Home

让人进屋,每个人到每个屋都是有代价的, 其实就是个最佳匹配,KM 算法,权值即是代价。 http://3214668848.blog.163.com/blog/static/487649192009102142141753/

Posted in POJ | Tagged , , | Leave a comment

POJ 2549 —— Sumsets

给定一个整数集合 S,求最大的 d,使得 a + b + c = d,并且 a,b,c,d 都是集合中的元素。 这个题目有多种弄法: 1、将元素排序,枚举 d,两个 for 循环求 b,c,二分查找 a。

Posted in POJ | Tagged , , | Leave a comment

POJ 2309 —— BST

这不就是树状数组的实现么?

Posted in POJ | Tagged | Leave a comment

POJ 1844 —— Sum

基本问题。 给定一个数 S,求一个 N,使得对从 1 到 N 的自然数进行加减之后能得到 S。

Posted in POJ | Tagged | Leave a comment

POJ 1828 —— Monkeys’ Pride

一批点。告知坐标,求有多少个点不在别的点和原点所形成的矩形当中。和http://www.chenyajun.com/2010/04/26/4992类似。

Posted in POJ | Tagged | Leave a comment

POJ 1018 —— Communication System

将 B 按照升序排列,枚举 B。

Posted in POJ | Tagged , | Leave a comment

HDU 1875 —— 畅通工程再续

最小生成树。 对于满足距离条件的那些点之间有边。 http://blog.csdn.net/huasonl88/archive/2009/08/25/4476752.aspx

Posted in other OJ | Tagged , | Leave a comment

POJ 1164 —— The Castle

dfs 即可。貌似很基本的问题。

Posted in POJ | Tagged | Leave a comment

POJ 2251 —— Dungeon Master

http://www.cppblog.com/liuhao/articles/102831.html 貌似不复杂。

Posted in POJ | Tagged , | Leave a comment

POJ 1458 —— Common Subsequence

最长公共子序列,DP。

Posted in POJ | Tagged , , | Leave a comment

POJ 1240 —— Pre-Post-erous!

一个 m 叉树,给定其前序和后序遍历,问其中序遍历方式有多少种。 基本问题。

Posted in POJ | Tagged , , | Leave a comment