Description ACM has bought a new crane (crane -- je?áb) . The crane consists of n segments of various lengths, connected by flexible joints. The end ....
分类:
其他好文 时间:
2015-01-01 22:26:01
阅读次数:
348
Crane
Time Limit: 2000MS
Memory Limit: 65536K
Total Submissions: 3777
Accepted: 1031
Special Judge
Description
ACM has bought a new crane (crane -- je?áb) . The...
分类:
其他好文 时间:
2014-11-26 11:30:47
阅读次数:
123
POJ 2991 Crane
题目链接
题意:给定一个垂直的挖掘机臂,有n段,现在每次操作可以旋转一个位置,把[s, s + 1]专程a度,每次旋转后要输出第n个位置的坐标
思路:线段树,把每一段当成一个向量,这样每一段的坐标就等于前几段的坐标和,然后每次旋转的时候,相当于把当前到最后位置全部加上一个角度,这样就需要区间修改了,然后每次还需要查询s,和s + 1当前的角度,所以需...
分类:
其他好文 时间:
2014-10-13 14:49:39
阅读次数:
272
题目链接:poj 2991 Crane
题目大意:就是有一个机械手臂,有n结,给定每节的长度,一开始为垂直的。有m次操作,每次将x关节变成角度d,并且输出手臂末端的坐标。
解题思路:点的旋转公式(r为逆时针的角度):
x′=x?cos(r)?y?sin(r)y′=x?sin(r)+y?cos(r)
没有做过类似的题目,线段树每个节点记录的为每节旋转的角度以及单节末端的位置。...
分类:
其他好文 时间:
2014-09-26 21:45:49
阅读次数:
218
题目链接题意:一个序列,你可以选择其中偶数长度的一段,然后中间切开,左右两段交换。现给你一个1~n的某个排列,求一个交换方案,使得排列最终有序。(交换次数 #include #include #include #include using namespace std;#define N 10100i...
分类:
其他好文 时间:
2014-09-26 14:13:18
阅读次数:
221
Description
ACM has bought a new crane (crane -- je?áb) . The crane consists of n segments of various lengths, connected by flexible joints. The end of the i-th segment is joined to the beginning...
分类:
其他好文 时间:
2014-08-14 16:50:28
阅读次数:
240
Description
ACM has bought a new crane (crane -- je?áb) . The crane consists of n segments of various lengths, connected by flexible joints. The end of the i-th segment is joined to the beginning o...
分类:
其他好文 时间:
2014-08-04 17:55:37
阅读次数:
240
本文以编译android平台下的kernel uboot,比较详尽地分析了lichee在sun4i_crane平台下编译的过程...
分类:
其他好文 时间:
2014-06-05 08:00:38
阅读次数:
256