- 博客(7)
- 资源 (3)
- 收藏
- 关注
原创 uva1493 - Draw a Mess 并查集路径压缩
It's graduated season, every students should leave something on the wall, so....they draw a lot of geometry shape with different color.When teacher come to see what happened, without getting angry,
2014-12-26 19:54:22 408
原创 Codeforces Round #283 (Div. 2) D. Tennis Game
D. Tennis Gametime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputPetya and Gena love playing table tennis. A single mat
2014-12-25 18:59:18 433
原创 uva11996 - Jewel Magic 伸展树
Problem JJewel MagicI am a magician. I have a string of emeralds and pearls. I may insert new jewels in the string, or remove old ones. I may even reverse a consecutive part of the string. At
2014-12-23 15:42:09 578
原创 uva11922 - Permutation Transformer 伸展树
Permutation Transformer Write a program to transform the permutation 1, 2, 3,..., n according to m instructions. Each instruction(a, b) means to take out the subsequence from thea-
2014-12-23 15:29:25 351
原创 伸展树
伸展树(Splay Tree),也叫分裂树,是一种二叉排序树,它能在O(log n)内完成插入、查找和删除操作。 旋转操作(左旋右旋)和前面的treap一样,伸展树最重要的操作是伸展操作,它把一个指定结点x自底向上旋转到根结点。分三种情况: 情况一:节点x的父节点y是根节点。这时,如果x是y的左孩子,我们进行一次Zig(右旋)操作;如果x是y的右孩子,则我们进行一次Zag(
2014-12-23 15:22:35 480
原创 uva1479 - Graph and Queries Treap名次树
You are given an undirected graph with N vertexes andM edges. Every vertex in this graph has an integer value assigned to it at the beginning. You're also given a sequence of operations and you need
2014-12-08 17:22:16 462
原创 uva12206 - Stammering Aliens 哈希LCP和后缀数组两种做法
Dr. Ellie Arroway has established contact with an extraterrestrialcivilization. However, all efforts to decode their messages have failed so farbecause, as luck would have it, they have stumbled upon
2014-12-01 17:43:20 902
表情多v0.2
2015-06-20
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人