Problem Description
The doggie found a bone in an ancient maze, which fascinated him a lot. However, when he picked it up, the maze began to shake, and the doggie could feel the ground sinking. He ...
分类:
其他好文 时间:
2015-02-25 09:11:35
阅读次数:
172
问题:
代码:
#include
#include
#include
using namespace std;
#define MaxSize 100
int maze[10][10] = //定义一个迷宫,0表示通道,1表示墙
{
{1,1,1,1,1,1,1,1,1,1},
{1,0,0,1,1,0,0,1,0,1},
{1,0,0,1,0,0,...
分类:
其他好文 时间:
2015-02-22 11:05:44
阅读次数:
155
Children of the Candy Corn
Time Limit: 1000MS
Memory Limit: 65536K
Total Submissions: 10380
Accepted: 4485
Description
The cornfield maze is a popular Halloween t...
分类:
其他好文 时间:
2015-02-17 14:09:21
阅读次数:
207
Maze Exploration
A maze of rectangular rooms is represented on a two dimensional grid as illustrated in figure 1a. Each point of the grid is represented by a character. The points of room walls are ...
分类:
其他好文 时间:
2015-02-14 08:45:35
阅读次数:
134
Problem Description
The doggie found a bone in an ancient maze, which fascinated him a lot. However, when he picked it up, the maze began to shake, and the doggie could feel the ground sinking. He realized that the bone was a trap, and he tried desperately...
分类:
其他好文 时间:
2015-02-12 16:21:54
阅读次数:
129
Children of the Candy CornTime Limit:1000MSMemory Limit:65536KTotal Submissions:10331Accepted:4466DescriptionThe cornfield maze is a popular Halloween...
分类:
其他好文 时间:
2015-02-12 10:43:47
阅读次数:
127
题意: 给出n个点,m条边,入口s和出口t,对于每条边有两个值a,b,如果保留这条边需要花费;否则,移除这条边需要花费b。
题目要求用最小费用构造一个有向图满足以下条件:
1.只有一个入口和出口
2.所有路都是唯一方向
3.对于入口s,它的出度 = 它的入度 + 1
...
分类:
其他好文 时间:
2015-02-09 18:36:44
阅读次数:
164
解题思路:
先用BFS预处理出每个字母节点到其它节点的最短路径,然后套用prime算法。
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#define LL long long
using namespace std;
const int ...
分类:
其他好文 时间:
2015-02-09 16:06:27
阅读次数:
181
传送门:Borg Maze题意:有一个迷宫,里面有一些外星人,外星人用字母A表示,#表示墙,不能走,空格可以走,从S点出发,在起点S和A处可以分叉走,问找到所有的外星人的最短路径是多少?分析:分别bfs由S和所有A出发到其他点的距离,然后建好图进行最小生成树处理即可。#include #includ...
分类:
其他好文 时间:
2015-02-06 21:41:54
阅读次数:
224
A - Fire!
Time Limit:1000MS Memory Limit:0KB 64bit IO Format:%lld
& %llu
SubmitStatus
Description
Problem B: Fire!
Joe works in a maze.
Unfortunately, portions of the maze have ...
分类:
其他好文 时间:
2015-02-03 09:36:18
阅读次数:
151