描述 The city executive board in Lund wants to construct a sightseeing tour by bus in Lund, so that tourists can see every corner of the beautiful city. ...
分类:
其他好文 时间:
2018-10-04 23:54:32
阅读次数:
216
[题目链接] https://codeforces.com/contest/666/problem/B [算法] 首先 , 用BFS求出任意两点的最短路径 然后 , 我们用f[i][0-2]表示从i出发到达的最远三点 , g[i][0-2]表示到i距离最远的三个点 枚举b和c , 然后在枚举3 * ...
分类:
其他好文 时间:
2018-10-02 18:04:15
阅读次数:
162
题目描述 Farmer John and his cows are planning to leave town for a long vacation, and so FJ wants to temporarily close down his farm to save money in the ...
分类:
其他好文 时间:
2018-09-30 18:21:01
阅读次数:
188
Problem UVA1347-Tour Accept: 667 Submit: 3866Time Limit: 3000 mSec Problem Description John Doe, a skilled pilot, enjoys traveling. While on vacation, ...
分类:
其他好文 时间:
2018-09-30 00:54:15
阅读次数:
180
dgraph 的查询语法是在graphql 上的扩展,添加了新的支持,同时官方提供了一个 学习的网站 https://tour.dgraph.io/ 基本环境(cluster 模式的) 参考 github 项目 https://github.com/rongfengliang/dgraph-dock ...
分类:
其他好文 时间:
2018-09-23 13:45:45
阅读次数:
937
题目描述 Farmer John has forgotten to repair a hole in the fence on his farm, and his N cows (1 <= N <= 1,000) have escaped and gone on a rampage! Each mi ...
分类:
其他好文 时间:
2018-09-22 21:22:29
阅读次数:
188
131072K After the long vacation, the maze designer master has to do his job. A tour company gives him a map which is a rectangle. The map consists of ...
分类:
其他好文 时间:
2018-09-13 01:23:18
阅读次数:
206
After the long vacation, the maze designer master has to do his job. A tour company gives him a map which is a rectangle. The map consists of N×M litt ...
分类:
其他好文 时间:
2018-09-09 19:58:18
阅读次数:
276
题目描述 In an effort to better manage the grazing patterns of his cows, Farmer John has installed one-way cow paths all over his farm. The farm consists ...
分类:
其他好文 时间:
2018-09-06 10:59:29
阅读次数:
155
基环树森林,然而我比较菜,直接tarjan找环。 发现缩点之后变成了DAG,每一个点往下走一定会走到一个环,缩点之后搜一遍看看会走到哪个环以及那个环的编号是多少,答案就是环的$siz$$ + $要走的路程。 比较垃圾的我忘记了判重边WA了好多发…… 时间复杂度$O(n)$。 Code: #inclu ...
分类:
其他好文 时间:
2018-09-06 02:31:26
阅读次数:
168