- 博客(20)
- 资源 (1)
- 收藏
- 关注
原创 windows安装scrapy
由于自己的电脑坏了抱去修了- - 用老爸的电脑只有windows,就在windows下装了个。。以下是安装步骤。。1.安装python下载地址:http://www.python.org/downloads/我载的是2.7.62.安装zope.interfacehttps://pypi.python.org/pypi/zope.interface#download验证是
2014-03-06 01:08:58 635
原创 uva 532 - Dungeon Master
//uva 532 - Dungeon Master//题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&category=105&problem=473&mosmsg=Submission+received+with+ID+10286403//题目大意是三维的
2012-07-04 00:33:58 417
原创 uva 439 - Knight Moves
//uva 439 - Knight Moves//题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=105&page=show_problem&problem=380//题目大意就是给出起点和终点,走日字,问最少多少次能到达//这题以前在hdu的diy上做过一次,这次一次A了
2012-07-04 00:32:52 351
原创 uva 705 - Slash Maze
// uva 705 - Slash Maze// 题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=105&page=show_problem&problem=646// 题目大意:求构成的环数以及最长环的长度// 第一次做斜线的搜索,想了挺久,一开始想的是用折射的思想,把每
2012-07-04 00:29:56 704
原创 uva 784 - Maze Exploration
// uva 784 - Maze Exploration// 题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=105&page=show_problem&problem=725// 题目大意:一个迷宫,人在*的地方,X是墙壁,将所有能到达的地方填充为##include #
2012-07-04 00:26:50 306
原创 uva 657 - The die is cast
// uva 657 - The die is cast// 题目链接: http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=105&page=show_problem&problem=598// 题目大意: 求每个区域内连通X的块数,然后排序输出// 一开始没注意到要排序,然后wa了,后
2012-07-04 00:25:28 354
原创 uva 572 - Oil Deposits
// uva 572 - Oil Deposits// 题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=105&page=show_problem&problem=513// 八方向用广搜,求连通的块数#include #include #include #includ
2012-07-04 00:24:08 382
原创 uva 10562 - Undraw the Trees
// uva 10562 - Undraw the Trees// 题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=104&page=show_problem&problem=1503// 题目大意:给出一棵树的图,把他翻译为括号的形式#include #include
2012-07-04 00:23:15 254
原创 uva 839 - Not so Mobile
// uva 839 - Not so Mobile// 题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=104&page=show_problem&problem=780// wr或wl为0的的话表示有子树,判断是否平衡, wl, dl, wr, dr 分别表示左端的重量,左
2012-07-04 00:22:55 356
原创 uva 327 - Evaluating Simple C Expressions
// uva 327 - Evaluating Simple C Expressions// 题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=104&page=show_problem&problem=263// 题目大意:给出一个算术表达式,输出这个算术表达式,算术表达式的值
2012-07-04 00:22:14 273
原创 uva 699 - The Falling Leaves
// uva 699 - The Falling Leaves// 题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=104&page=show_problem&problem=640// 题目大意:给出一棵二叉树先序遍历的结果,-1表示节点为空,每个节点垂直往下落叶,落叶的数量
2012-07-04 00:21:47 300
原创 uva 712 - S-Trees
// uva 712 - S-Trees// 题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=104&page=show_problem&problem=653// 题目大意:x3, x1, x2表示每一层是哪个节点,0表示往左,1表示往右,之后给出的001 111什么都是按照
2012-07-04 00:21:03 421
原创 uva 297 - Quadtrees
// uva 297 - Quadtrees// 题目链接: http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=104&page=show_problem&problem=233// 题目大意: 每附图分成32X32,将部分染上黑色,将两附图合并,求黑色总数#include #incl
2012-07-04 00:20:29 363
原创 uva 548 - Tree
// uva 548 - Tree// 题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=104&page=show_problem&problem=489// 题目大意: 求从根节点到叶节点路径和最小的叶节点,如果有多组,输出叶节点最小的#include #include
2012-07-04 00:19:30 288
原创 uva 112 - Tree Summing
// uva 112 - Tree Summing// 题目链接:http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=104&page=show_problem&problem=48// 题目大意: 给一个整数n和一颗树,求是否存在一条从根节点到叶节点的和等于这个整数#include #
2012-07-04 00:18:47 332
原创 poj3468_A Simple Problem with Integers_线段树_成段更新求和
//poj3468 A Simple Problem with Integers//线段树成段更新求和//一开始忘记了数据量大,用的cin,结果一直TLE,ORZ。。。//据说要用什么lazy-tag思想,我也不太清楚这算不算//思路就是每个节点加上一个add,如果某一段从left都到right全部都增加val的话,add加上val,然后就不往下更新了//如果之后算的在这范围之内,求和的
2012-06-03 18:05:54 298
原创 poj3264_Balanced Lineup_线段树
//poj3264 Balanced Lineup//线段树#include #include #include using namespace std;const int MAXN = 50010;struct MinMax{ int min, max;};struct Node{ struct MinMax minmax; int left, right;}tree
2012-06-03 18:02:24 213
原创 hdoj1754_I Hate It_线段树_单点更新求最值
//hdoj1754 I Hate It//线段树,单点更新求最值#include #include #include using namespace std;const int MAXN = 200010;#define L(x) (x) << 1#define R(x) (x) << 1 | 1struct Node{ int left ,right; int max;
2012-06-03 18:01:27 249
原创 hdoj1166_排兵布阵(线段树、树状数组)
//hdoj1166 排兵布阵//做的第一题线段树。。。#include #include #include using namespace std;const int MAXN = 50010;struct Node{ int sum; int left, right;}tree[MAXN * 3];int arr[MAXN];int nN, nCase;void bu
2012-06-03 17:51:55 420
原创 2012百度之星初赛第二场ProblemC
//2012百度之星初赛第二场ProblemC//这题用是贪心,按照差值从大到小排序,差值相同的按两种礼物得分总和从大到小排序//然后大的优先选择礼物#include #include #include #include using namespace std;struct Friend{ int a, b; int x, y; int dlt;}friends[1010]
2012-06-03 17:47:43 1802 1
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人