# 文章标题

Dining Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 19461 Accepted: 8670 DescriptionCows are such finicky eaters. Each cow has a preference for certain foods and drinks, an...

# POJ 1236(强连通分量+Kosaraju)

Limit: 1000MS Memory Limit: 10000K Total Submissions: 19625 Accepted: 7732 DescriptionA number of schools are connected to a computer network. Agreements have been developed among those s...

# HDU 5536（01字典树）

John is a manager of a CPU chip factory, the factory produces lots of chips everyday. To manage large amounts of products, every processor has a serial number. More specifically, the factory produces n...

# HDU 3336 Count the strings(KMP+DP)

It is well known that AekdyCoin is good at string problems as well as number theory problems. When given a string s, we can write down all the non-empty prefixes of this string. For example: s: “abab...

# HDU 1358 Peroid(KMP和循环节)

For each prefix of a given string S with N characters (each character has an ASCII code between 97 and 126, inclusive), we want to know whether the prefix is a periodic string. That is, for each i (2 <...

# HDU 3746 Cyclic Nacklace (KMP和循环节)

CC always becomes very depressed at the end of this month, he has checked his credit card yesterday, without any surprise, there are only 99.9 yuan left. he is too distressed and thinking about how to...

# HDU 1686 Oulipo (KMP查找可交叉区间模式串)

The French author Georges Perec (1936–1982) once wrote a book, La disparition, without the letter ‘e’. He was a member of the Oulipo group. A quote from the book: Tout avait Pair normal, mais tout s’af...

# HDU 1711 Number Sequence (KMP模板)

Given two sequences of numbers : a[1], a[2], …… , a[N], and b[1], b[2], …… , b[M] (1 <= M <= 10000, 1 <= N <= 1000000). Your task is to find a number K which make a[K] = b[1], a[K + 1] = b[2], …… , a[K...

# Frogs(容斥+数论)

There are mm stones lying on a circle, and nn frogs are jumping over them. The stones are numbered from 00 to m−1m−1 and the frogs are numbered from 11 to nn. The ii-th frog can jump over exactly aia...

# Watto and Mechanism（字符串hash算法）

Watto, the owner of a spare parts store, has recently got an order for the mechanism that can process strings in a certain way. Initially the memory of the mechanism is filled with n strings. Then the...

# LCA 模板

A rooted tree is a well-known data structure in computer science and engineering. An example is shown below: In the figure, each node is labeled with an integer from {1, 2,…,16}. Node 8 is the root of...

# HDU 1698 Just A Hook（线段树修改区间到某值）

In the game of DotA, Pudge’s meat hook is actually the most horrible thing for most of the heroes. The hook is made up of several consecutive metallic sticks which are of the same length.  No...

# Puzzles (树形dp+组合数学)

Barney lives in country USC (United States of Charzeh). USC has n cities numbered from 1 through n and n - 1 roads between them. Cities and roads of USC form a rooted tree (Barney’s not sure why it is...

# Contestant Division(树形dp)

In the new ACM-ICPC Regional Contest, a special monitoring and submitting system will be set up, and students will be able to compete at their own universities. However there’s one problem. Due to the...

# God Father (树形dp 树的重心)

Last years Chicago was full of gangster fights and strange murders. The chief of the police got really tired of all these crimes, and decided to arrest the mafia leaders.Unfortunately, the structure of...

83条 共5页1 2 3 4 5 ... 下一页 尾页
个人资料
• 访问：5123次
• 积分：837
• 等级：
• 排名：千里之外
• 原创：77篇
• 转载：0篇
• 译文：1篇
• 评论：0条
阅读排行