----dfs
文章平均质量分 84
_Occult_
物語が始まった
展开
-
PAT (Top Level) Practise 1019 Separate the Animals (35)
1019. Separate the Animals (35)时间限制1000 ms内存限制65536 kB代码长度限制8000 B判题程序Standard作者LIU, RujiaThere are some animals in a zoo whic原创 2017-11-09 14:47:20 · 1020 阅读 · 1 评论 -
HDU 2589 正方形划分
Problem Description一个边长为L的正方形可以分成 L*L个小正方形. 有N个石子放在 N个小正方形里,能否将它分成 N个 正方形,使得每个正方形里恰有一个石子且这N 个正方形恰好构成整个正方形 . Input输入数据首先包含一个整数T,表示测试实例的个数,然后是T组数据,每组第一行包含2个整数L,N,接下来有N行每行2个整数 r,c,表示第r行原创 2016-07-12 17:20:23 · 576 阅读 · 4 评论 -
HDU 2821 Pusher
Problem DescriptionPusherBoy is an online game http://www.hacker.org/push . There is an R * C grid, and there are piles of blocks on some positions. The goal is to clear the blocks by pushing into原创 2016-07-12 17:08:15 · 374 阅读 · 0 评论 -
PAT (Advanced Level) Practise 1094 The Largest Generation (25)
1094. The Largest Generation (25)时间限制200 ms内存限制65536 kB代码长度限制16000 B判题程序Standard作者CHEN, YueA family hierarchy is usually prese原创 2016-03-25 19:23:56 · 377 阅读 · 0 评论 -
PAT (Advanced Level) Practise 1114 Family Property (25)
1114. Family Property (25)时间限制150 ms内存限制65536 kB代码长度限制16000 B判题程序Standard作者CHEN, YueThis time, you are supposed to help us col原创 2016-03-26 21:48:14 · 1103 阅读 · 0 评论 -
PAT (Advanced Level) Practise 1107 Social Clusters (30)
1107. Social Clusters (30)时间限制1000 ms内存限制65536 kB代码长度限制16000 B判题程序Standard作者CHEN, YueWhen register on a social network, you ar原创 2016-03-26 15:50:47 · 490 阅读 · 0 评论 -
PAT (Advanced Level) Practise 1102 Invert a Binary Tree (25)
1102. Invert a Binary Tree (25)时间限制400 ms内存限制65536 kB代码长度限制16000 B判题程序Standard作者CHEN, YueThe following is from Max Howell @twi原创 2016-03-26 13:44:02 · 435 阅读 · 0 评论 -
PAT (Advanced Level) Practise 1099 Build A Binary Search Tree (30)
1099. Build A Binary Search Tree (30)时间限制100 ms内存限制65536 kB代码长度限制16000 B判题程序Standard作者CHEN, YueA Binary Search Tree (BST) is r原创 2016-03-26 12:30:15 · 455 阅读 · 3 评论 -
PAT (Advanced Level) Practise 1068 Find More Coins (30)
1068. Find More Coins (30)时间限制150 ms内存限制65536 kB代码长度限制16000 B判题程序Standard作者CHEN, YueEva loves to collect coins from all over t原创 2016-03-22 21:06:31 · 595 阅读 · 0 评论 -
PAT (Advanced Level) Practise 1090 Highest Price in Supply Chain (25)
1090. Highest Price in Supply Chain (25)时间限制200 ms内存限制65536 kB代码长度限制16000 B判题程序Standard作者CHEN, YueA supply chain is a network原创 2016-03-25 18:07:13 · 414 阅读 · 0 评论 -
PAT (Advanced Level) Practise 1079 Total Sales of Supply Chain (25)
1079. Total Sales of Supply Chain (25)时间限制250 ms内存限制65536 kB代码长度限制16000 B判题程序Standard作者CHEN, YueA supply chain is a network of原创 2016-03-25 12:59:05 · 454 阅读 · 0 评论 -
PAT (Top Level) Practise 1006 Tree Traversals - Hard Version (35)
1006. Tree Traversals - Hard Version (35)时间限制400 ms内存限制65536 kB代码长度限制8000 B判题程序Standard作者CHEN, YueGiven the partial results of原创 2016-02-28 12:13:25 · 5577 阅读 · 4 评论 -
HDU 1043 Eight
Problem DescriptionThe 15-puzzle has been around for over 100 years; even if you don't know it by that name, you've seen it. It is constructed with 15 sliding tiles, each with a number from 1 to 1原创 2015-04-01 17:25:03 · 631 阅读 · 5 评论 -
ZOJ 3924 Musical Notes
DescriptionBesides his skills of playing Hearthstone, Bob is also insterested in learning piano in order to make himself more charming, of course, to Alice.Now, Bob had transcribed a musical sco原创 2016-03-08 18:22:20 · 541 阅读 · 0 评论 -
HDU 3313 Key Vertex
Problem DescriptionYou need walking from vertex S to vertex T in a graph. If you remove one vertex which stops you from walking from S to T, that vertex we call as key vertex. Now you are given a原创 2016-07-12 17:25:22 · 331 阅读 · 0 评论 -
HDU 3316 Mine sweeping
Problem DescriptionI think most of you are using system named of xp or vista or win7.And these system is consist of a famous game what is mine sweeping.You must have played it before.If you not,ju原创 2016-07-12 17:27:33 · 369 阅读 · 0 评论 -
CSU 1566 The Maze Makers
The Maze Makers is a publisher of puzzle books. One of their most popular series is maze books. They have a program that generates rectangular two-dimensional mazes like the one shown in Figure 1. The原创 2017-07-29 19:49:51 · 329 阅读 · 0 评论 -
CSU 1563 Lexicography
An anagram of a string is any string that can be formed using the same letters as the original. (We consider the original string an anagram of itself as well.) For example, the string ACM has the foll原创 2017-07-29 19:44:43 · 307 阅读 · 0 评论 -
CSU 1562 Fun House
American Carnival Makers Inc. (ACM) has a long history of designing rides and attractions. One of their more popular attractions is a fun house that includes a room of mirrors. Their trademark is to s原创 2017-07-29 19:41:23 · 340 阅读 · 0 评论 -
ZOJ 1609 Equivalence
When learning mathamatics, sometimes one may come to an theorem which goes like this:The following statements are equivalent:a)......b)......c)......For example, let A be an angle between原创 2017-04-16 22:48:45 · 334 阅读 · 0 评论 -
ZOJ 2418 Matrix
Given an n*n matrix A, whose entries Ai,j are integer numbers ( 0 SHIFT at row i ( 0 <= i < n ) will move the integers in the row one position right, and the rightmost integer will wrap around to the原创 2017-04-19 13:25:20 · 346 阅读 · 0 评论 -
PAT (Top Level) Practise 1004 To Buy or Not to Buy - Hard Version (35)
1004. To Buy or Not to Buy - Hard Version (35)时间限制400 ms内存限制65536 kB代码长度限制8000 B判题程序Standard作者CHEN, YueEva would like to make原创 2016-02-28 12:05:28 · 1319 阅读 · 1 评论 -
HDU 4876 ZCC loves cards
ZCC loves playing cards. He has n magical cards and each has a number on it. He wants to choose k cards and place them around in any order to form a circle. He can choose any several consecutive cards原创 2017-03-02 13:56:17 · 314 阅读 · 0 评论 -
ZOJ 3332 Strange Country II
DescriptionYou want to visit a strange country. There are n cities in the country. Cities are numbered from 1 to n. The unique way to travel in the country is taking planes. Strangely, in this str原创 2016-03-08 18:15:34 · 291 阅读 · 0 评论 -
PAT (Top Level) Practise 1012 Greedy Snake (35)
1012. Greedy Snake (35)时间限制1000 ms内存限制65536 kB代码长度限制8000 B判题程序Standard作者LIU, RujiaHave you ever played the game "Greedy Snake"原创 2016-09-12 21:51:40 · 1261 阅读 · 0 评论 -
POJ 3083 Children of the Candy Corn
DescriptionThe cornfield maze is a popular Halloween treat. Visitors are shown the entrance and must wander through the maze facing zombies, chainsaw-wielding psychopaths, hippies, and other terro原创 2016-08-27 19:41:03 · 493 阅读 · 0 评论 -
HDU 2209 翻纸牌游戏
Problem Description有一种纸牌游戏,很有意思,给你N张纸牌,一字排开,纸牌有正反两面,开始的纸牌可能是一种乱的状态(有些朝正,有些朝反),现在你需要整理这些纸牌。但是麻烦的是,每当你翻一张纸牌(由正翻到反,或者有反翻到正)时,他左右两张纸牌(最左边和最右边的纸牌,只会影响附近一张)也必须跟着翻动,现在给你一个乱的状态,问你能否把他们整理好,使得每张纸牌都正面朝上,如果可以原创 2016-07-13 21:36:45 · 516 阅读 · 0 评论 -
HDU 4127 Flood-it!
Problem DescriptionFlood-it is a fascinating puzzle game on Google+ platform. The game interface is like follows:At the beginning of the game, system will randomly generate an N×N square boa原创 2016-07-12 17:44:10 · 434 阅读 · 0 评论 -
HDU 4101 Ali and Baba
Problem DescriptionThere is a rectangle area (with N rows and M columns) in front of Ali and Baba, each grid might be one of the following:1. Empty area, represented by an integer 0.2. A Stone原创 2016-07-12 17:42:14 · 437 阅读 · 0 评论 -
HDU 3427 Clickomania
Problem DescriptionClickomania is a puzzle in which one starts with a rectangular grid of cells of different colours. In each step, a player selects ("clicks") a cell. All connected cells of the s原创 2016-07-12 17:34:03 · 500 阅读 · 0 评论 -
HDU 2475 Box
DescriptionThere are N boxes on the ground, which are labeled by numbers from 1 to N. The boxes are magical, the size of each one can be enlarged or reduced arbitrarily. Jack can perform the “MO原创 2016-02-23 12:36:04 · 1064 阅读 · 0 评论 -
HDU 5636 Shortest Path
Problem DescriptionThere is a path graph G=(V,E) with n vertices. Vertices are numbered from 1 to n and there is an edge with unit length between i and i+1 (1≤in). To make the graph more int原创 2016-03-05 23:48:26 · 829 阅读 · 5 评论 -
POJ 3460 Booksort
DescriptionThe Leiden University Library has millions of books. When a student wants to borrow a certain book, he usually submits an online loan form. If the book is available, then the next day原创 2015-07-18 21:49:39 · 1072 阅读 · 0 评论 -
ZOJ 1003 Crashing Balloon
DescriptionOn every June 1st, the Children's Day, there will be a game named "crashing balloon" on TV. The rule is very simple. On the ground there are 100 labeled balloons, with the numbers 1原创 2015-07-18 21:41:41 · 393 阅读 · 0 评论 -
ACdream 1726 A Math game
DescriptionRecently, Losanto find an interesting Math game. The rule is simple: Tell you a number H, and you can choose some numbers from a set {a[1],a[2],......,a[n]}.If the sum of the number you原创 2015-07-18 21:20:39 · 594 阅读 · 0 评论 -
HDU 5323 Solve this interesting problem
Problem DescriptionHave you learned something about segment tree? If not, don’t worry, I will explain it for you.Segment Tree is a kind of binary tree, it can be defined as this:- For each nod原创 2015-07-28 19:16:45 · 745 阅读 · 0 评论 -
POJ 3548 Restoring the digits
DescriptionLet's consider arithmetic expressions (addition or subtraction) over non-negative decimal integers. The expression syntax is as follows:the first operand;the operator sign ('+' or原创 2015-07-26 17:02:51 · 398 阅读 · 0 评论 -
HDU 5311 Hidden String
Problem DescriptionToday is the 1st anniversary of BestCoder. Soda, the contest manager, gets a string ss of length nn. He wants to find three nonoverlapping substrings s[l_1..r_1]s[l1..r1原创 2015-07-26 17:11:33 · 375 阅读 · 0 评论 -
POJ 2570 Fiber Network
DescriptionSeveral startup companies have decided to build a better Internet, called the "FiberNet". They have already installed many nodes that act as routers all around the world. Unfortunatel原创 2015-07-26 17:00:27 · 331 阅读 · 0 评论 -
ACdream 1431 Sum vs Product
Description Peter has just learned mathematics. He learned how to add, and how to multiply. The fact that 2 + 2 = 2 × 2 has amazed him greatly. Now he wants find more such examples. Peters原创 2015-05-22 15:38:46 · 441 阅读 · 0 评论