
poj
文章平均质量分 69
talak
这个作者很懒,什么都没留下…
展开
-
1401 poj Factorial
简单数学题,我却不会做 - -!!! Description The most importantpart of a GSM network is so called Base Transceiver Station (BTS).These transceivers form the areas called cells (this term gave thename to the cellu原创 2012-05-25 22:37:35 · 414 阅读 · 0 评论 -
count color
本题是个线段树的题目 听人说也是比较入门的线段树 本人新手刚学 不太了解 debug了一天 由于对线段树的结构不太了解 这里做下总结,有错误的地方望大神们指出,本人新手难免出错,望嘴下留情 线段树每次都只能前一半和后一半的区间,并不能包括所有的区间,只有由一个个的不断分成一半一半的区间来组合所有需要的区间 在我看来线段树貌似对于有些题目必须要 保持的不间断的区间的问题就有难度了 在原创 2012-09-04 22:58:27 · 1044 阅读 · 0 评论 -
poj 2352 stars
初学树状数组练手 题目就是 给你个二维平面 和一些点 对于每个点左下角有多少个点 那就是多少等级(包括边界) 让你输出0到N-1的等级数 http://poj.org/problem?id=2352 因为给你的数是按Y升序给的 对象Y相等的事按X升序 省去了自己排序 用树状数组直接算X前面有多少个点 代码: #include #include #include #inc原创 2012-08-31 12:20:30 · 407 阅读 · 0 评论 -
big number poj 1423
哎,用log10函数做 在程序内打表,在查表,不会超时,但为什么一边输入一边算会超时啊,两个的最坏的情况不是一样么 代码: #include #include #include #include #include #include #include #include using namespace std; int main() { int T,a; scan原创 2012-09-06 20:32:30 · 446 阅读 · 0 评论 -
buy low buy lower
第一问很水,最长下降子序列 第二问很麻烦,我不会做,不仅要考虑每一种情况,还要判重,第一次找别人的题解,居然是错代码,当时我那个悲剧啊,第二次找了位大神的,代码很简洁,所以仿照他的写了一遍代码,也是有点模糊的懂,算了先挂在这里吧 #include #include #include using namespace std; #define maxN 5010 int dp[maxN],k原创 2012-08-06 17:16:28 · 937 阅读 · 0 评论 -
poj 1511
http://poj.org/problem?id=1511 最短路问题 dijkstra邻接表+优先队列算法 正面算一次,反图算一次 题目明明说的不超long long 全部改成long long 才过 代码: #include #include #include #include #include #include #include #include us原创 2012-09-19 17:28:59 · 480 阅读 · 0 评论 -
poj 2485 Highway
http://poj.org/problem?id=2485 最小生成树 模板题 kruscal算法 代码: #include #include #include #include #include #include #include #include #include using namespace std; int p[505]; struct node {原创 2012-11-12 22:27:17 · 447 阅读 · 0 评论