![](https://img-blog.csdnimg.cn/20201014180756724.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
UVa
文章平均质量分 86
七情六欲·
唔西迪西 糊不拉几
展开
-
UVA - 818 Cutting Chains 深度好文 仔细研读
What a find! Anna Locke has just bought several links of chain some of which may be connected. Theyare made from zorkium, a material that was frequently used to manufacture jewelry in the last century,but is not used for that purpose anymore. It has its原创 2021-03-10 16:20:19 · 2186 阅读 · 0 评论 -
UVA - 806 Spatial Structures
Computer graphics, image processing, and GIS (geographic information systems) all make use of a datastructure called a quadtree. Quadtrees represent regional or block data efficiently and support efficientalgorithms for operations like the union and inte原创 2021-03-02 20:22:20 · 170 阅读 · 0 评论 -
UVa 753 A Plug for UNIX EK算法即可
You are in charge of setting up the press room for the inaugural meeting of the United Nations InterneteXecutive (UNIX), which has an international mandate to make the free flow of information and ideason the Internet as cumbersome and bureaucratic as po原创 2021-02-22 10:25:44 · 161 阅读 · 0 评论 -
UVA 12661 Funny Car Racing
There is a funny car racing in a city with n junctions and m directed roads.The funny part is: each road is open and closed periodically. Each road is associate with twointegers (a, b), that means the road will be open for a seconds, then closed for b se原创 2021-02-17 12:55:46 · 132 阅读 · 0 评论 -
UVA 658 It‘s not a Bug, it‘s a Feature!
It is a curious fact that consumers buying a new software product generally do not expect the softwareto be bug-free. Can you imagine buying a car whose steering wheel only turns to the right? Or aCD-player that plays only CDs with country music on them?原创 2021-02-17 12:16:58 · 166 阅读 · 0 评论 -
UVa1151 Buy or Build
World Wide Networks (WWN) is a leading company that operates large telecommunication networks.WWN would like to setup a new network in Borduria, a nice country that recently managed to get ridof its military dictator Kurvi-Tasch and which is now seeking原创 2021-02-14 19:09:52 · 136 阅读 · 0 评论 -
UVA - 12219 Common Subexpression Elimination
Let the set Σ consist of all words composed of 1-4 lower case letters, such as the words “a”, “b”, “f”,“aa”, “fun” and “kvqf”. Consider expressions according to the grammar with the two rulesE → fE → f(E, E)for every symbol f ∈ Σ. Any expression can ea原创 2021-02-14 14:00:53 · 264 阅读 · 0 评论 -
UVA - 122 Trees on the level
Trees on the levelTrees are fundamental in many branches of computer science (Pun definitely intended). Current stateof-the art parallel computers such as Thinking Machines’ CM-5 are based on fat trees. Quad- andoctal-trees are fundamental to many algori原创 2021-01-19 20:42:01 · 121 阅读 · 0 评论 -
UVA - 210 Concurrency Simulator
UVA - 210 Concurrency SimulatorPrograms executed concurrently on a uniprocessor system appear to be executed at the same time, butin reality the single CPU alternates between the programs, executing some number of instructions fromeach program before sw原创 2021-01-19 20:03:08 · 96 阅读 · 0 评论 -
UVA - 815 Flooded!
FloodedTo enable homebuyers to estimate the cost of flood insurance, a real-estate firm provides clients withthe elevation of each 10-meter by 10-meter square of land in regions where homes may be purchased.Water from rain, melting snow, and burst water原创 2021-01-14 15:16:44 · 110 阅读 · 0 评论 -
UVA - 12108 Extraordinarily Tired Students
When a student is too tired, he can’t help sleeping in class, even if his favorite teacher is right here infront of him. Imagine you have a class of extraordinarily tired students, how long do you have to wait,before all the students are listening to you原创 2021-01-12 17:12:44 · 107 阅读 · 0 评论 -
UVA - 220 Othello
Othello is a game played by two people on an 8 x 8 board, using disks that are white on one side andblack on the other. One player places disks with the white side up and the other player places diskswith the black side up. The players alternate placing原创 2021-01-11 22:10:25 · 169 阅读 · 0 评论 -
UVA - 1587 Box
Ivan works at a factory that produces heavy machinery. He has a simple job — he knocks up woodenboxes of different sizes to pack machinery for delivery to the customers. Each box is a rectangularparallelepiped. Ivan uses six rectangular wooden pallets to原创 2021-01-11 13:50:01 · 112 阅读 · 0 评论 -
UVA - 227 Puzzle
A children’s puzzle that was popular 30 years ago consisted of a 5×5 frame which contained 24 smallsquares of equal size. A unique letter of the alphabet was printed on each small square. Since therewere only 24 squares within the frame, the frame also c原创 2021-01-11 13:32:34 · 106 阅读 · 0 评论 -
UVA - 340 Master-Mind Hint
MasterMind is a game for two players. One of them, Designer, selects a secret code. The other, Breaker,tries to break it. A code is no more than a row of colored dots. At the beginning of a game, the playersagree upon the length N that a code must have a原创 2021-01-10 17:14:25 · 89 阅读 · 0 评论 -
UVA - 12325 Zombie‘s Treasure Chest 僵尸的宝藏
Zombie’s Treasure ChestSome brave warriors come to a lost village. They are very lucky and find a lot of treasures and a bigtreasure chest, but with angry zombies.The warriors are so brave that they decide to defeat the zombies and then bring all the tr原创 2020-09-02 20:33:01 · 160 阅读 · 0 评论 -
UVa140 Bandwidth
Given a graph (V, E) where V is a set of nodes and E is a set of arcs inV ×V , and an ordering on the elements in V , then the bandwidth of anode v is defined as the maximum distance in the ordering...原创 2020-02-24 15:51:47 · 137 阅读 · 0 评论 -
UVa 725 Division 和 UVa 11059 Maximum Product
Write a program that finds and displays all pairs of 5-digit numbers that between them use the digits 0through 9 once each, such that the first number divided by the second is equal to an integer N, ...原创 2020-02-24 11:33:23 · 139 阅读 · 0 评论 -
UVa1601 The Morning after Halloween
【写在最前】 本题应该是双向BFS的最基本的题目,但是我还是看了题解,某种程度上还是抄了代码,其实抛开本题的双向BFS不说,本题的预处理就值得我们竖起大拇指了,好好理解You are working for an amusement park as an operator of an obakeyashiki, or a haunted house, inwhich guests walk...原创 2020-02-20 23:26:49 · 179 阅读 · 0 评论 -
第一百题 UVAa750 8 Queens Chess Problem 目之所及 皆是遗憾
终于写够一百道题啦,怎么也没想过他是这样来临的,在一个阳光明媚的冬日,写完第九十九题之后还是非常激动的,不知道第一百题做什么好,ACM群里不知怎么的就讨论起了八皇后问题(好像还是因为我发了一个非常奇怪的问题求解答)我犹豫了三分钟之后,算了,干脆写个八皇后问题吧,这题很熟悉,但是现在却已经都忘记了题目是什么样子的,又翻了出来。。。。In chess it is possible to place ...原创 2020-02-18 17:40:52 · 221 阅读 · 0 评论 -
第九十九题 UVa225 Golygons
第九十九题了,还是好激动的…Imagine a country whose cities have all their streets laid out in a regular grid. Now suppose that atourist with an obsession for geometry is planning expeditions to several such citie...原创 2020-02-18 17:16:53 · 241 阅读 · 0 评论 -
第九十七题 UVA1595 对称轴 Symmetry
The figure shown on the left is left-right symmetric as it is possible to fold the sheet of paper along avertical line, drawn as a dashed line, and to cut the figure into two identical halves. The fi...原创 2020-02-18 15:19:21 · 186 阅读 · 0 评论 -
第九十五题 UVa11214 Guarding the Chessboard
Given an n ∗ m chessboard with some marked squares, your task isto place as few queens as possible to guard (attack or occupy) allmarked squares. Below is a solution to an 8 ∗ 8 board with everysqu...原创 2020-02-18 11:43:33 · 222 阅读 · 0 评论 -
第九十四题 UVa12107 Digit Puzzle
If you hide some digits in an integer equation, you create a digit puzzle. The figure below shows twovalid digit puzzles. Hidden digits are represented by squares, and other digits are shown. The num...原创 2020-02-17 13:51:44 · 141 阅读 · 0 评论 -
第九十二题 UVa 1354 Mobile Computing
今天一天一共做了立两道题,但是第二题个人觉得也是很有思维难度,并且从洛谷上给出的提高+/省选的难度标签也证实了猜测。There is a mysterious planet called Yaen, whose space is 2-dimensional. There are many beautifulstones on the planet, and the Yaen people lo...原创 2020-02-14 22:13:39 · 139 阅读 · 0 评论 -
第九十一题 UVa129 Krypton Factor
You have been employed by the organisers of a Super Krypton Factor Contest in which contestantshave very high mental and physical abilities. In one section of the contest the contestants are tested o...原创 2020-02-14 15:00:59 · 149 阅读 · 0 评论 -
第九十题 UVa524 Prime Ring Problem
A ring is composed of n (even number) circles as shown in diagram.Put natural numbers 1, 2, . . . , n into each circle separately, and thesum of numbers in two adjacent circles should be a prime.No...原创 2020-02-13 14:58:03 · 100 阅读 · 0 评论 -
第八十九题 UVa246 10-20-30
A simple solitaire card game called 10-20-30 uses a standard deck of 52 playing cards in which suit isirrelevant. The value of a face card (king, queen, jack) is 10. The value of an ace is one. The v...原创 2020-02-13 12:09:36 · 330 阅读 · 0 评论 -
第八十八题 UVa804 Petri Net Simulation
A Petri net is a computational model used to illustrate concurrent activity. Each Petri net contains somenumber of places (represented by circles), transitions (represented by black rectangles), and ...原创 2020-02-11 15:24:39 · 306 阅读 · 0 评论 -
第八十七题 UVa12166 Equilibrium Mobile
A mobile is a type of kinetic sculpture constructed totake advantage of the principle of equilibrium. It consists of a number of rods, from which weighted objectsor further rods hang. The objects ha...原创 2020-02-11 10:19:25 · 221 阅读 · 0 评论 -
第八十六题 UVa712 S-Trees
今天正月十七了,正月十五没学习,昨天又去打了一天球也没学习,最近题做的真的很慢,行百里者半九十,更何况我还有没到九十,这几天冲一冲进度A Strange Tree (S-tree) over the variable set Xn = {x1, x2, . . . , xn} is a binary tree representing aBoolean function f : {0, 1}...原创 2020-02-10 14:28:19 · 144 阅读 · 0 评论 -
第八十五题 UVa422 Matrix Chain Multiplication
Suppose you have to evaluate an expression like ABCDE where A,B,C,D and E are matrices.Since matrix multiplication is associative, the order in which multiplications are performed is arbitrary.Howev...原创 2020-02-07 21:52:16 · 195 阅读 · 0 评论 -
第八十四题UVa514 Rails
There is a famous railway station in PopPush City. Country there is incredibly hilly. The stationwas built in last century. Unfortunately, funds were extremely limited that time. It was possible toe...原创 2020-02-07 20:40:31 · 256 阅读 · 0 评论 -
第八十三题 UVa400 Unix ls
The computer company you work for is introducing a brand new computer line and is developing anew Unix-like operating system to be introduced along with the new computer. Your assignment is towrite ...原创 2020-02-06 23:25:37 · 175 阅读 · 0 评论 -
第八十二题 UVA540 团体队列 Team Queue
Sample Input23 101 102 1033 201 202 203ENQUEUE 101ENQUEUE 201ENQUEUE 102ENQUEUE 202ENQUEUE 103ENQUEUE 203DEQUEUEDEQUEUEDEQUEUEDEQUEUEDEQUEUEDEQUEUESTOP25 259001 259002 259003 259004...原创 2020-02-06 15:49:10 · 182 阅读 · 0 评论 -
第八十一题 UVa12096 The SetStack Computer
Background from Wikipedia: “Set theory is abranch of mathematics created principally by theGerman mathematician Georg Cantor at the end ofthe 19th century. Initially controversial, set theoryhas c...原创 2020-02-05 21:14:08 · 184 阅读 · 0 评论 -
第八十题 UVa213 Message Decoding
Some message encoding schemes require that an encoded message be sent in two parts. The first part,called the header, contains the characters of the message. The second part contains a pattern thatr...原创 2020-02-05 14:41:00 · 132 阅读 · 0 评论 -
第七十九题 UVa1368 DNA Consensus String
DNA (Deoxyribonucleic Acid) is the molecule which contains the genetic instructions. It consists of four differentnucleotides, namely Adenine, Thymine, Guanine, and Cytosine as shown in Figure 1. If ...原创 2020-02-05 13:04:07 · 159 阅读 · 0 评论 -
第七十八题 UVa1583 Digit Generator
【分析】直接看代码就能看懂,只需要解释一下 那个50 为什么是50呢,这其实取决于n的位数 乘以十,题目好像没有明确说明 n有多大,我就写了个五十(也就是n最多是个五位数),然后就AC了//// Created by DELL on 2020/2/4.//#include <iostream>#include <cstring>#include &l...原创 2020-02-04 17:06:25 · 112 阅读 · 0 评论 -
第七十七题 UVa10082 WERTYU
还是水题但是有两个CLion的小问题搞得我好难受【题目大意】对于每个字符,输出它在键盘上左边的字符//// Created by DELL on 2020/2/4.//代码是很简单 另外写一篇关于CLion的小博客 可以去看 最近发现处理的问题#include <iostream>#include <cstring>#include <...原创 2020-02-04 13:26:37 · 143 阅读 · 0 评论