码迷,mamicode.com
首页 >  
搜索关键字:usaco 2008 mar gold    ( 2941个结果
USACO maze1 BFS
好久不写bfs了,中间失误了好长时间,在扩展新节点的时候一旦扩展成功就应该标记节点为已访问,不然有些情况下会无限扩展队列。题目的输入处理略坑爹,可以先当字符串读进来,然后用一个数组标记每个节点四周墙的情况,最后从两个出口搜索一遍,用流水填充,最后取两遍的较小值,然后取整个地图的最大值作为结果 /* ID:kevin_s1 PROG:maze1 LANG:C++ */ #include #in...
分类:其他好文   时间:2014-07-20 10:00:56    阅读次数:326
USACO Section 2.1 The Castle
/* ID: lucien23 PROG: castle LANG: C++ */ /************************************************************************/ /* 求图的连通域问题,利用广度扫描 */ /******...
分类:其他好文   时间:2014-07-19 02:41:25    阅读次数:226
USACO Section 2.1 Ordered Fractions
/* ID: lucien23 PROG: frac1 LANG: C++ */ #include #include #include #include using namespace std; typedef struct Fraction { int numerator; int denominator; Fraction(){} Fraction(int x, int y...
分类:其他好文   时间:2014-07-19 02:31:25    阅读次数:199
USACO Section 2.1 Sorting a Three-Valued Sequence
/* ID: lucien23 PROG: sort3 LANG: C++ */ #include #include #include #include using namespace std; void exchange(int nums[], int begin, int end, int N, int x); int sum = 0; int main() { ifstream ...
分类:其他好文   时间:2014-07-19 02:12:25    阅读次数:176
How to Use the UTL_MAIL Package
APPLIES TO:PL/SQL - Version 10.1.0.2 and laterInformation in this document applies to any platform."Checked for relevance on 06-Mar-2012"GOALThis note...
分类:其他好文   时间:2014-07-18 15:04:26    阅读次数:253
(Step1-500题)UVaOJ+算法竞赛入门经典+挑战编程+USACO
下面给出的题目共计560道,去掉重复的也有近500题,作为ACMer Training Step1,用1年到1年半年时间完成。打牢基础,厚积薄发。一、UVaOJhttp://uva.onlinejudge.org西班牙Valladolid大学的程序在线评测系统,是历史最悠久、最著名的OJ。二、《算法...
分类:其他好文   时间:2014-07-18 11:39:04    阅读次数:483
[POJ 1390]Blocks
Description Some of you may have played a game called 'Blocks'. There are n blocks in a row, each box has a color. Here is an example: Gold, Silver, Silver, Silver, Silver, Bronze, Bronze, Bronze, Go...
分类:其他好文   时间:2014-07-18 11:23:05    阅读次数:280
USACO cowtour Floyd + 枚举
给出来的数据量还是可以的。题意:有若干个牧场,至少有两个不连通,一个牧场的直径就是牧场中最远的两个牧区的距离。要求找出几个牧场中最短的直径,就是找一条路径连接几个牧区,使这个直径最终最小。 基本方法,把整个图根据输入划分成几个不连通的牧区,然后求出每个牧区的直径(即每个连通块中的最长路径),然后枚举两个不在同一牧区的点,设blocks[i]记录第i个节点所在连通块的直径,那么result = m...
分类:其他好文   时间:2014-07-18 11:04:46    阅读次数:287
一个支持实时预览的在线 Markdown 编辑器 - Markdoc
最近组内需要为一些项目和系统写文档,发表在公司内的文档平台上,这个平台并不支持markdown,所以打算做一个在线markdown编辑器,支持实时预览,并且可以很容易的迁移发表到公司文档平台上,所以就有了这个 Markdoc。在线地址:http://weareoutman.github.io/mar...
分类:其他好文   时间:2014-07-18 08:05:23    阅读次数:272
[POI 2001+2014acm上海邀请赛]Gold Mine/Beam Cannon 线段树+扫描线
Description  Byteman, one of the most deserving employee of The Goldmine of Byteland, is about to retire by the end of the year. The Goldmine management would like to reward him in acknowledgment...
分类:其他好文   时间:2014-07-17 10:24:12    阅读次数:307
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!