A Round Peg in a Ground Hole Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 4438 Accepted: 1362 Description The DIY Furniture company specializes in assemble-it-yourself furniture kits. Typically, the pieces of wood are attached to on…
问题 H: Planar map 时间限制: 1 Sec 内存限制: 128 MB提交: 24 解决: 22[提交][状态][讨论版] 题目描述 Tigher has work for a long time in a famous company.One day she is given a planar map(look at the following) and a point.The planar map can be regarded as a polygon.The planar…
链接: http://acm.timus.ru/problem.aspx?space=1&num=1348 http://acm.hust.edu.cn/vjudge/contest/view.action?cid=27498#problem/A 1348. Goat in the Garden 2 Time limit: 1.0 second Memory limit: 64 MB A goat is tied to a peg (in a point C) in a garden with…
1719: [Usaco2006 Jan] Roping the Field 麦田巨画 Time Limit: 5 Sec Memory Limit: 64 MBSubmit: 82 Solved: 26[Submit][Status][Discuss] Description Farmer John is quite the nature artist: he often constructs large works of art on his farm. Today, FJ wants…
Bridge Across Islands Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 7632 Accepted: 2263 Special Judge Description Thousands of thousands years ago there was a small kingdom located in the middle of the Pacific Ocean. The territory…
题目 Link 分析 典型的树链剖分题, 树链剖分学习资料 Code #include <bits/stdc++.h> using namespace std; const int maxn = 30000 + 131; struct Edge { int Next; int To; }edge[maxn<<1]; int Head[maxn], tot, n; ///以下是重链数据定义 int top[maxn]; //重链的顶点 int deep[maxn]; //树上节点的深…
Peter and Snow Blower 题意:有n(3 <= n <= 100 000)个点的一个多边形,这个多边形绕一个顶点转动,问扫过的面积为多少? 思路:开始就认为是一个凸包的问题,像poj2187求点对平方的最大值一样,但是有一个点是确定的(ps:这道题在div1里面可是A啊!这么复杂?),所以直接求解即可,时间复杂度也就O(n);还有就是怎么求多边形到确定点的最小距离呢?这就不只是暴力求点对之间的距离这么简单了.因为一个多边形绕一个点转动时,有时候是定点到边的距离,所以转化为了点…
描述 https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=2896 两只狗分别沿着各自的折线匀速跑,同时出发,同时到达.求其间它们两的最大距离和最小距离之差. 11796Dog DistanceTwo dogs, Ranga and Banga, are running randomly following twodifferent paths…