 Rubik's Cube

Problem Description
You are a secret agent for the Eternally Indebted External Intelligence Office (EIEIO) of the country of Nomoneo. Headquarters has disguised your onetime pad for encrypted communications in the form of a Rubik's Cube? (For those of you unfamiliar with the puzzle, a Rubik's Cube?comes in the form of a cube where each face is divided into three rows and three columns (nine "squares". Any of the six faces of the cube may be rotated either clockwise or counterclockwise, which also rotates the three nearest squares on each adjoining face onto a new face, respectively. When solved (or taken from the factory packaging), each face of the cube contains squares of only one color. There is no way to change the relationship between the colors of the central squares on each face.) The cube has been prescrambled and you are to apply a certain set of moves to the cube based on the message you want to return.
This diagram provides the relationship between the sides of the cube as well as the orientation of the faces for the purposes of input and output. It should be viewed as an unfolded cube with the text on the outside. The faces are indicated by the color of the central subdivision (square) and are White, Orange, Red, Blue, Green, and Yellow. The corner with the dot is the top left corner for purposes of input and output.Input
Your program should read the input data from the file, which consists of several cases. The first line of the input will give the number of these input cases (as a decimal integer without any punctuation), which will be greater than or equal to 1 and less than or equal to 10,000. Each case consists of three lines giving the initial state of the puzzle cube and one line giving the rotations you must apply to reach the appropriate final state of the cube.
Each of the three lines giving the initial state of the cube consists of 18 letters with a single space between each pair of letters. There is no space between the last letter and the end of the line. Each of the letters is 'W', 'O', 'R', 'B', 'G', or 'Y' indicating the respective color. The faces are listed from left to right in the order (by central square color) White, Orange, Red, Blue, Green, Yellow. Thus, the first three columns of letters give the state of the "White" face, and so forth.
The fourth line of the case gives the manipulations that you must apply to the cube. Each manipulation consists of a single letter as above ('W', 'O', 'R', 'B', 'G', or 'Y') indicating which face (selected by the color of the center) you should rotate. Each rotation thus indicated is a 90?clockwise rotation of the face with respect to the rest of the cube, looking at the face to be rotated. At least one and no more than 1,000 manipulations will be specified.Output
Print to standard output the state of the cube after the indicated manipulations. Use the same format as for input: three lines, each containing 18 color letters separated by a single space character. Do not put a space after the final letter on the line. Print out the faces in the same order, left to right, as for input: White, Orange, Red, Blue, Green, Yellow. After each output case, print a line containing 35 '=' characters.Sample Input
2
W W W O O O R R R B B B G G G Y Y Y
W W W O O O R R R B B B G G G Y Y Y
W W W O O O R R R B B B G G G Y Y Y
RG
Y G G Y G W Y W B R W O R W G B G G
O W R Y O B G R O R B O Y G R B Y Y
O W O G O W Y B W B R W B B O R Y R
GROWBOBGROWSample Output
O O O Y Y Y R R R Y Y Y G G G B Y O
W W W O O O R R R B B B G G G B Y OB B B W W W R R R W W W G G G B Y O
W G R Y B G B R G B O W O R B R W R
G W B G O R G R R Y B B O G O Y Y BG W R Y Y Y W W O G O W O Y B Y W O
The Errant Physicist _course
20171126Problem Description The wellknown physicist Alfred E Neuman is working on problems that involve multiplying polynomials of x and y. For example, he may need to calculate getting the answer Unfortunately, such problems are so trivial that the great man's mind keeps drifting off the job, and he gets the wrong answers. As a consequence, several nuclear warheads that he has designed have detonated prematurely, wiping out five major cities and a couple of rain forests. You are to write a program to perform such multiplications and save the world. Input The file of input data will contain pairs of lines, with each line containing no more than 80 characters. The final line of the input file contains a # as its first character. Each input line contains a polynomial written without spaces and without any explicit exponentiation operator. Exponents are positive nonzero unsigned integers. Coefficients are also integers, but may be negative. Both exponents and coefficients are less than or equal to 100 in magnitude. Each term contains at most one factor in x and one in y. Output Your program must multiply each pair of polynomials in the input, and print each product on a pair of lines, the first line containing all the exponents, suitably positioned with respect to the rest of the information, which is in the line below. The following rules control the output format: 1.Terms in the output line must be sorted in decreasing order of powers of x and, for a given power of x, in increasing order of powers of y. 2.Like terms must be combined into a single term. For example, 40x2y3  38x2y3 is replaced by 2x2y3. 3.Terms with a zero coefficient must not be displayed. 4.Coefficients of 1 are omitted, except for the case of a constant term of 1. 5.Exponents of 1 are omitted. 6.Factors of x0 and y0 are omitted. 7.Binary pluses and minuses (that is the pluses and minuses connecting terms in the output) have a single blank column both before and after. 8.If the coefficient of the first term is negative, it is preceded by a unary minus in the first column, with no intervening blank column. Otherwise, the coefficient itself begins in the first output column. 9.The output can be assumed to fit into a single line of at most 80 charactes in length. 10.There should be no blank lines printed between each pair of output lines. 11.The pair of lines that contain a product should be the same lengthtrailing blanks should appear after the last nonblank character of the shorter line to achieve this. Sample Input yx8+9x31+y x5y+1+x3 1 1 # Sample Output 13 2 11 8 6 5 5 2 3 3 x y  x y + 8x y + 9x  x y + x y + 8x + x y  1 + y 1
Knights of the Round Table _course
20171012Description Being a knight is a very attractive career: searching for the Holy Grail, saving damsels in distress, and drinking with the other knights are fun things to do. Therefore, it is not very surprising that in recent years the kingdom of King Arthur has experienced an unprecedented increase in the number of knights. There are so many knights now, that it is very rare that every Knight of the Round Table can come at the same time to Camelot and sit around the round table; usually only a small group of the knights isthere, while the rest are busy doing heroic deeds around the country. Knights can easily get overexcited during discussionsespecially after a couple of drinks. After some unfortunate accidents, King Arthur asked the famous wizard Merlin to make sure that in the future no fights break out between the knights. After studying the problem carefully, Merlin realized that the fights can only be prevented if the knights are seated according to the following two rules: The knights should be seated such that two knights who hate each other should not be neighbors at the table. (Merlin has a list that says who hates whom.) The knights are sitting around a roundtable, thus every knight has exactly two neighbors. An odd number of knights should sit around the table. This ensures that if the knights cannot agree on something, then they can settle the issue by voting. (If the number of knights is even, then itcan happen that ``yes" and ``no" have the same number of votes, and the argument goes on.) Merlin will let the knights sit down only if these two rules are satisfied, otherwise he cancels the meeting. (If only one knight shows up, then the meeting is canceled as well, as one person cannot sit around a table.) Merlin realized that this means that there can be knights who cannot be part of any seating arrangements that respect these rules, and these knights will never be able to sit at the Round Table (one such case is if a knight hates every other knight, but there are many other possible reasons). If a knight cannot sit at the Round Table, then he cannot be a member of the Knights of the Round Table and must be expelled from the order. These knights have to be transferred to a lessprestigious order, such as the Knights of the Square Table, the Knights of the Octagonal Table, or the Knights of the BananaShaped Table. To help Merlin, you have to write a program that will determine the number of knights that must be expelled. Input The input contains several blocks of test cases. Each case begins with a line containing two integers 1 ≤ n ≤ 1000 and 1 ≤ m ≤ 1000000 . The number n is the number of knights. The next m lines describe which knight hates which knight. Each of these m lines contains two integers k1 and k2 , which means that knight number k1 and knight number k2 hate each other (the numbers k1 and k2 are between 1 and n ). The input is terminated by a block with n = m = 0 . Output For each test case you have to output a single integer on a separate line: the number of knights that have to be expelled. Sample Input 5 5 1 4 1 5 2 5 3 4 4 5 0 0 Sample Output 2
Pie Bridge _course
20170420It is the Valentine's day! Yue Lao decides to have a meeting for the magpies to construct the pie bridge(magpie bridge). There are N magpies in the sky. In order to hold a meeting, Yue Lao should make all the magpies at the same place in the same time. A magpie can be consider as a dot in the 2dplane. Initially, all the magpies stay still in some place. The only instruction Yue Lao can do is to push a magpie. Yue Lao can push a magpie in any direction. After Yue Lao pushs a magpie, the magpie starts moving in that direction with a constant speed. Yue Lao's power is limited, so there is a limit for the speed of the magpie: the horizontal speed can't exceed vx and the vertical speed can't exceed vy. Yue Lao can push a magpie at most once. Besides, Yue Lao can't push magpies too often. After a push, he needs to rest at least t seconds for the next push. When two magpies meet at the same point, they will not collide with each other and will stay moving or stay still. Now the question is, what is the minumum time it needs to take for Yue Lao to achieve his goal (make all the magpies moves to the same place at the same time)? Input There are multiple test cases. There are two parts for each case. The first part is one line with four integers N, vx, vy and t (2 <= N <= 9, 0 < vx, vy <= 100, 0 <= t <= 100), represent the number of magpies, the horizontal speed limit, the vertical speed limit, and the time interval Yue Lao needs to rest between two pushes. The second part consists with N lines. Each line consists of two integers xi and yi (1000000 <= xi, yi <= 1000000), represent the coordinate for the ith magpie. There will not be two different magpies in the same point initially. Output The output of each test case should be a single line, the minimum time for Yue Lao to achieve his goal. All result that have relative or absolute error less than 1E6 will be accepted. Sample Input 2 1 1 1 0 0 0 7 Sample Output 4.000000000000000
As A Wlohe _course
20170419Aoccdrnig to a rscheearch at Cmabrigde Uinervtisy, it deosn't mttaer in waht oredr the ltteers in a wrod are, the olny iprmoetnt tihng is taht the frist and lsat ltteer be at the rghit pclae. The rset can be a toatl mses and you can sitll raed it wouthit porbelm. Tihs is bcuseae the huamn mnid deos not raed ervey lteter by istlef, but the wrod as a wlohe. Or rather... According to a researcher at Cambridge University, it doesn't matter in what order the letters in a word are, the only important thing is that the first and last letter be at the right place. The rest can be a total mess and you can still read it without problem. This is because the human mind does not read every letter by itself but the word as a whole. Input The input file first gives the dictionary of the words with length less than 20, ended by a line containing "DICTIONARY_DEFINE_OVER". Then, zero or more lines follow that line, each with a sentence. The sentences contain the messed up words that consist of only lowercase characters. There are punctuations that will only appear at the two ends of some words. NOTE, there will be exactly one original word in the dictionary for each word in the sentences. The size of dictionay is not larger than 10000 and there will be at most 1000 sentences each contains at most 80 characters. Output Output the original sentence for each line of sentence in a line. Sample Input all luck good fun have watashi with is it really totally amazing prada this fact these words are not used agree DICTIONARY_DEFINE_OVER wtaahsi:"raelly? tihs fcat is amzanig~~" pdara:"ttaloly aegre wtih it." hvae fun all, good lcuk~~ Sample Output watashi:"really? this fact is amazing~~" prada:"totally agree with it." have fun all, good luck~~
A Bunch Of Monsters _course
20161122Description Background Jim is a brave explorer. One day, he set out for his next destination, a mysterious hill. When he arrived at the foot of the hill, he was told that there were a bunch of monsters living in that hill, and was dissuaded from continuing his trip by the residents near the hill. Nevertheless, our Jim was so brave that he would never think of giving up his exploration. The monsters do exist! When he got into that hill, he was caught by a bunch of fearful monsters. Fortunately, the monsters didn’t plan to kill him or eat him for they were planning a big party. They wanted to invite Jim, a clever human being, to their party, in order to let human beings know that the monsters also have wonderful parties. Problem At the end of the party, the monsters promised that, after the last game, they would set Jim free. The game is described as follow: 1. There are a great many boxes of treasure, which are numbered from 1 to X. One box has the only one number; one number can only appear on one box. Furthermore, we can assume that X is INFINITY, because the monsters have got a lot of treasure from the men they caught. 2. There are N monsters in this game. Each picks up a card randomly. After that, he / she (it?) opens it, getting a positive integer number d[i], and cannot change it or pick up another card again. The range of d[i] is from 1 to M. If the ith monster get the number d[i], he can only get the treasure box numbered equal to or less than d[i]. What’s more, one box only can be distributed to one monster; one monster can only get one box. 3. Of course, there are many ways to distribute the boxes to the monsters when N monsters get their numbers; and not every monster can get a box in many cases. Jim has the right to make the arrangement; however, he also knows that the monsters that don’t get the boxes will also punish him. Jim knows the strength of the N monsters. The ith one has the strength s[i]. We call the sum of strength s[i] of all the monsters that don’t get the boxes  the DAMAGE to Jim. Your task is to help Jim find out the minimum DAMAGE to him. Input The input consists of several test cases. In the first line of each test case, there are two positive integers N and M (1<=N<=50000, 1<=M<=50000), indicating the number of monsters and the range of numbers the monsters possibly get on the cards. Then there are N integers d[i] (1<=d[i]<=M) in the following lines, which are the numbers those monsters got. And in the rest lines of one test case, there are other N positive integers s[i] (1<=s[i]<=20000), indicating the strength of each monsters. The test case starting with 2 zeros is the final test case and has no output. Output For each test case, print your answer, the minimum DAMAGE, in one line without any redundant spaces. Sample Input 1 1 1 1 7 7 6 4 4 2 3 4 3 10 70 20 60 30 50 40 0 0 Sample Output 0 50
Ten drops _course
20170410Have you ever played the flash game "10 drops" before? I have tried this game several times, but I am not good at playing this game because of my bad imagination. So I come to you, one of the best programmers in the world, for help. The target is to find the status of the grid after several given actions. Do you think that is too easy? But, to me, it is an impossible mission. So, if you help me to solve it, I'll appreciate it. INSTRUCTIONS: You start with m drops in your tank; Use them to grow blobs until they burst; We use a number 0 <= x < k to describe the size of the blob: 0 indicate there is no blobs, and a blob with a given size k will burst. Once a drop attach to a blob, the size of it will increase by 1. The burst blob will release four drops moving in four directions, and they move in the same speed. If a drop moves to a grid which contains a blob, the blob will grow. What's more, if more than one drops move to the same grid simultaneously, you can assume that the one comes from north (up) attaches the blob first, then south second, west third and east last. An action is a left click in some grid in the game (the left top one is (0,0), and (0,1) is to the east of (0,0)). A left click indicates that you use 1 drop in your tank (if it's not empty) to grow the blob in that grid. Of cause, a left click in grid without blob should be ignored because it's meaningless. Input There are multiple test cases. Each case begins with a line containing four integer n, m, k, p where n < 20 indicates the size of the grid is n * n; m <= 1000 is the number of rest drops in your tank; k <= 10 is the burst size of blob; and p is the number of actions. The next n lines each with n integers less than k. And then p lines each with 2 integers x, y stand for an action. Both x and y are less than n. Process to the end of file. Output Print the number of left drops after p actions in tank in a line. Then print the description of the grid after p actions as the input shows. Print a blank line between cases. Sample Input 6 10 5 3 002243 423200 030132 132214 143213 403202 1 2 2 1 3 1 6 10 5 4 002243 423200 030132 132214 143213 403202 1 2 2 1 3 1 2 1 Sample Output 7 002243 424200 040132 142214 143213 403202 6 003243 000400 000232 304214 204213 403202
Perfect Cherry Blossom _course
20170827In Gensokyo, people relax and bask in the calm of a winter without end. Spring has shown no sign of arriving even though it's already May, and in fact the snowstorms are continually getting worse. Kirisame Marisa, a playful magician, sees a cherry blossom petal float down outside her warm house and wonders if spring is happening somewhere else. She follows the trail of cherry blossoms high above Gensokyo, eventually crosses a great magical boundary into the Netherworld. At the end of a long journey, she comes face to face with Saigyouji Yuyuko, the ghost princess of Hakugyokurou, who had been stealing the essence of "spring" throughout Gensokyo in order to make the Saigyou Ayakashi, a youkai cherry tree, bloom perfectly with the rest of Hakugyokurou's gardens. And Marisa defeats her to reclaim Gensokyo's spring. perfect_cherry_blossom_0.jpg Assume that Marisa starts the journey at any point of line y=1 and ends at line y=S. After each unit time, she can move from point (x1, y) to point (x2, y + 1), 0 <= x < W, where dy = x1  x2 is the distance she moves in xdirection. If Marisa appears in the same point with a bullet or a item, then she will be struck by the bullet or get the item, respectively. Marisa's aim is to get as many cherry points as possible during the journey. There are many things linking with the cherry points: When Marisa starts off her journey, she has 0 cherry points; Shooting enemies increases Marisa's cherry points, she can gain at most B cherry points in total in this way, where B is a given constant; Being struck by bullets decreases Marisa's cherry points by a certain number zi for each bullet; Gathering pink items (cherry blossom petals) increases Marisa's cherry points by a certain number zj for each item; Grazing bullets by having them pass through her sprite but not her hitbox increases Marisa's cherry points. But it's not an easy job, especially when she has to move in xdirection to avoid bullets or gather items. She can gain at most C  A * d (maybe negative, it's valid) cherry points in total in this way, where C and A are constants, d is the total distance she moves in xdirection. This means that the more Marisa moves in xdirection, the less cherry points she can gain. Marisa wants to know how many cherry points she can get at most. Input There are no more than 100 cases, most of which are small ones. Process to the end of file. Each case begins with 6 integers 1 <= W <= 30000, 1 <= S <= 900000000, 0 <= N <= 60000, 0 <= A <= 10, 0 <= B <= 100000000 and 0 <= C <= 1000000000. Then N lines. The kth line describe a bullet or a item at point (Xk, Yk) by 3 integers 0 <= Xk < W, 0 <= Yk < S and 0 < Zk < 10000. A positive Zk stands for a pink item, while a negative one stands a bullet. All (Xk, Yk) are different. Output The maximum possible cherry points on separate lines. Sample Input 2 3 3 0 0 0 0 0 1 1 1 1 0 2 1 6 6 6 6 6 6 3 0 3 3 1 3 3 2 3 3 3 3 2 3 4 4 3 2 Sample Output 0 18
Flying Stars _course
20170914Description When pop stars make their international tours they usually prefer to spend as little time as possible for travel and to save more time for rehearsal, shows and for their private life. Therefore they travel only by airplanes and constantly search for the fastest route to destination. However, nowadays there are so many possibilities for traveling that finding the fastest way for a long distant trip is not an easy task. That is why a program capable to solve this problem would be prized on the market and you as an independent software developer are strongly encouraged to write such a program. Since pop stars travel only by airplanes your task is greatly simplified. You need to take into account only international airports and flights connecting them. There are some facts about a journey by airplanes that you should know: international airports are located in different time zones, each airport has flight schedule which defines destination, departure time and travel time for each flight; this schedule works on daily basis, boarding the airplane (as well as changing from one airplane to another) takes time, which differs from one airport to another. To formalize the problem, we make the following steps: all international airport names are coded as identifiers represented by sequences of no more than 20 alphanumeric characters or underline characters (i.e. 'a'...'z', 'A'...'Z', '0'...'9' or '_'); all identifiers are unique, all flight identifiers are combination of company code and flight number with a total length of no more than 5 alphanumeric characters; all such identifiers are unique, all identifiers are case sensitive, all data which represent time have a format of "hh:mm", where "hh" and "mm" are digits from '0' to '9' representing hours and minutes respectively; if not specified otherwise the local time is used. Using these assumptions, you should write a program to find the fastest route from the airport of origin to the destination one. Input The first line of the input file contains identifiers of the airports of origin and of destination and starting time of the journey separated by spaces. The starting time is the time when pop star arrives to the airport of origin. The second line of the input file contains single integer N. This integer represents the number of international airports and is not less than 2 and not greater than 100. The rest of the input file consists of descriptions of international airports. Each description starts with a headline and may contain some complementary lines. The headline consists of the airport identifier, airport time zone, boarding time and integer M separated by spaces. Time zone is time difference between local time and Greenwich Mean Time and has a format of "shh:mm", where "s" is the sign of time difference and are either "+" or "". Boarding time is the time delay needed for boarding or airplane change in that particular airport. Integer M defines a number of flights in the airport schedule (not greater than 300), each flight is described on its separate line following the headline. The description of the flight consists of the flight identifier, destination airport identifier, departure time and travel time, separated by spaces. The travel time is the time gap between departure and landing (arrival). The task will always have a solution for the given data. Output In the first line of the output file your program should print the total travel time which is counted from the moment when pop star arrives to the airport of origin till the moment of arrival to the destination airport using the format of "d:hh:mm", where "d" is the number of full days of travel (no trip can last more than 9 full days). In the second line the program should print the local time of the arrival of the star to the destination airport. In the following lines program should print the list of flight identifiers of the best route  one flight identifier per line. Sample Input Pulkovo JFK 11:15 3 Pulkovo +03:00 01:30 2 BA347 Heathrow 12:10 04:25 Z8805 Heathrow 18:25 04:30 Heathrow +00:00 00:45 3 BA160 JFK 09:20 08:10 BA346 Pulkovo 14:45 04:20 Z8804 Pulkovo 21:30 04:25 JFK 05:00 00:45 1 BA161 Heathrow 14:25 08:05 Sample Output 1:09:15 12:30 Z8805 BA160
Lost in Space _course
20170228William Robinson was completely puzzled in the music room; he could not find his triangle in his bag. He was sure that he had prepared it the night before. He remembered its clank when he had stepped on the school bus early that morning. No, not in his dream. His triangle was quite unique: no two sides had the same length, which made his favorite peculiar jingle. He insisted to the music teacher, Mr. Smith, that his triangle had probably been stolen by those aliens and thrown away into deep space. Your mission is to help Will find his triangle in space. His triangle has been made invisible by the aliens, but candidate positions of its vertices are somehow known. You have to tell which three of them make his triangle. Having gone through wormholes, the triangle may have changed its size. However, even in that case, all the sides are known to be enlarged or shrunk equally, that is, the transformed triangle is similar to the original. Input The very first line of the input has an integer which is the number of data sets. Each data set gives data for one incident such as that of William. At least one and at most ten data sets are given. The first line of each data set contains three decimals that give lengths of the sides of the original triangle, measured in centimeters. Three vertices of the original triangle are named P, Q, and R. Three decimals given in the first line correspond to the lengths of sides QR, RP, and PQ, in this order. They are separated by one or more space characters. The second line of a data set has an integer which is the number of points in space to be considered as candidates for vertices. At least three and at most thirty points are considered. The rest of the data set are lines containing coordinates of candidate points, in light years. Each line has three decimals, corresponding to x, y, and z coordinates, separated by one or more space characters. Points are numbered in the order of their appearances, starting from one. Among all the triangles formed by three of the given points, only one of them is similar to the original, that is, ratios of the lengths of any two sides are equal to the corresponding ratios of the original allowing an error of less than 0.01 percent. Other triangles have some of the ratios different from the original by at least 0.1 percent. The origin of the coordinate system is not the center of the earth but the center of our galaxy. Note that negative coordinate values may appear here. As they are all within or close to our galaxy, coordinate values are less than one hundred thousand light years. You don't have to take relativistic effects into account, i.e., you may assume that we are in a Euclidean space. You may also assume in your calculation that one light year is equal to 9.461x10^12 kilometers. A succeeding data set, if any, starts from the line immediately following the last line of the preceding data set. Output For each data set, one line should be output. That line should contain the point numbers of the three vertices of the similar triangle, separated by a space character. They should be reported in the order P, Q, and then R. Sample Input 2 50.36493 81.61338 79.96592 5 10293.83 4800.033 5296.238 14936.30 6964.826 7684.818 4516.069 25748.41 27016.06 18301.59 11946.25 5380.309 27115.20 43415.93 71607.81 11.51547 13.35555 14.57307 5 56292.27 2583.892 67754.62 567.5082 756.2763 118.7268 1235.987 213.3318 216.4862 317.6108 54.81976 55.63033 22505.44 40752.88 27482.94 Sample Output 1 2 4 3 4 2
Intercepting Missiles _course
20161226Description Our country is under enemy's attack. Hostile bombers are going to fly towards the capital and destroy everything. To defend the capital, we have a number of missiles, ready to launch and hit the enemy's bombers, before they reach the capital. Unfortunately, there are passenger planes in the sky, which we do not want to hit by our missiles. We have been able to gather useful information regarding enemy's bombers. While they taxi over our missile defense zone, bombers travel in a fixed altitude. All bombers fly with the same speed. The same applies to airplanes, and our missiles. We know the location of each bomber and each airplane at time zero. Our missiles are placed on the ground, and their locations are also known. You should write a program, that given the information about the bombers, and the locations of passenger planes in the sky, determines the maximum number of bombers that can be successfully hit by our missiles. Then, we pray for the rest of bombers to explode by themselves! To simplify your task, The following are assumed: We consider a flat twodimensional model of the earth. Thus, the ycoordinate of the airplanes, and attacking bombers, does not change during their movement over our defense zone. Each defending missile can be fired, at time zero or afterwards. The ycoordinate of bombers, and airplanes are distinct positive integers. Each bomber or airplane, has unit length, while our missiles have no length. If a missile hits, or just touches the edge of a target in the sky, our missile will explode, while the target keeps moving normally on its path for a while before it explodes. Assume that the hit bomber will explode after passing all defending missiles, i.e. after surpassing the xcoordinate of all our missiles. Note that during this time, it may be hit by other missiles. Input The input file contains multiple test cases. The first line of the input, contains t, the number of test cases that follow. Each of the following t blocks, describes a test case, and is preceded by a blank line. The first line of each block contains three integers, m, n and k (0 ≤ m, n, k ≤ 300), which are the number of bombers, airplanes, and our missiles, respectively. The second line contains three integers, vm, vn, and vk (1 ≤ vm, vn, vk ≤ 10, 000), which are the respective velocity of bombers, airplanes and our missiles. Airplanes and enemy’s bombers, are assumed to move to the right, for simplicity, while our missile move upwards, without changing their xcoordinates. Next come m lines, that each gives the x and y coordinate of the head of a bomber, at time zero. The planes in the sky, are described similarly, in the following n lines. The last line contains k integers, each being the xcoordinate of a defending missile which is ready to launch. The coordinates are all nonnegative integers less than 10, 000. Output For each test case, output one line showing the maximum number of hit bombers, without any airplane being hit. Follow the format of the sample. Sample Input 1 2 1 3 1 1 1 0 100 1 99 2 50 100 200 300 Sample Output Mission #1: 1 bomber(s) exploded
Building a Space Station _course
20170901You are a member of the space station engineering team, and are assigned a task in the construction process of the station. You are expected to write a computer program to complete the task. The space station is made up with a number of units, called cells. All cells are sphereshaped, but their sizes are not necessarily uniform. Each cell is fixed at its predetermined position shortly after the station is successfully put into its orbit. It is quite strange that two cells may be touching each other, or even may be overlapping. In an extreme case, a cell may be totally enclosing another one. I do not know how such arrangements are possible. All the cells must be connected, since crew members should be able to walk from any cell to any other cell. They can walk from a cell A to another cell B, if, (1) A and B are touching each other or overlapping, (2) A and B are connected by a `corridor', or (3) there is a cell C such that walking from A to C, and also from B to C are both possible. Note that the condition (3) should be interpreted transitively. You are expected to design a configuration, namely, which pairs of cells are to be connected with corridors. There is some freedom in the corridor configuration. For example, if there are three cells A, B and C, not touching nor overlapping each other, at least three plans are possible in order to connect all three cells. The first is to build corridors AB and AC, the second BC and BA, the third CA and CB. The cost of building a corridor is proportional to its length. Therefore, you should choose a plan with the shortest total length of the corridors. You can ignore the width of a corridor. A corridor is built between points on two cells' surfaces. It can be made arbitrarily long, but of course the shortest one is chosen. Even if two corridors AB and CD intersect in space, they are not considered to form a connection path between (for example) A and C. In other words, you may consider that two corridors never intersect. Input The input consists of multiple data sets. Each data set is given in the following format. n x1 y1 z1 r1 x2 y2 z2 r2 ... xn yn zn rn The first line of a data set contains an integer n, which is the number of cells. n is positive, and does not exceed 100. The following n lines are descriptions of cells. Four values in a line are x, y and zcoordinates of the center, and radius (called r in the rest of the problem) of the sphere, in this order. Each value is given by a decimal fraction, with 3 digits after the decimal point. Values are separated by a space character. Each of x, y, z and r is positive and is less than 100.0. The end of the input is indicated by a line containing a zero. Output For each data set, the shortest total length of the corridors should be printed, each in a separate line. The printed values should have 3 digits after the decimal point. They may not have an error greater than 0.001. Note that if no corridors are necessary, that is, if all the cells are connected without corridors, the shortest total length of the corridors is 0.000. Sample Input 3 10.000 10.000 50.000 10.000 40.000 10.000 50.000 10.000 40.000 40.000 50.000 10.000 2 30.000 30.000 30.000 20.000 40.000 40.000 40.000 20.000 5 5.729 15.143 3.996 25.837 6.013 14.372 4.818 10.671 80.115 63.292 84.477 15.120 64.095 80.924 70.029 14.881 39.472 85.116 71.369 5.553 0 Sample Output 20.000 0.000 73.834
MySQL基础入门视频课程
20181127本课程从零开始，以通俗易懂的方式讲解MySQL技术，手把手教你掌握每一个知识点。课程中使用的所有英文单词都会逐一查询并记录，真正做到零基础入门学习，适合初学者的教程！ 课程内容包括： 1.MySQL简介、安装MySQL 2.查询操作 3.聚合函数和分组统计 4.更新操作 5.表和库的管理 6.约束 7.用户和权限管理 8.事务处理 教学全程采用笔记+代码案例的形式讲解，通俗易懂！！！
 3.64MB
Xshell6完美破解版，亲测可用
20181226Xshell6破解版，亲测可用，分享给大家。直接解压即可使用
Java进阶高手课Java基础编程提升
20200427课程聚焦Java基础编程提升的核心知识点，以真实场景项目实战为导向，循序渐进，深入浅出的了解Java基础编程，讲解Java这门使用广泛的编程语言，助你能够游刃有余地游走在这些技术之中。
Linux系统编程：入门篇视频教程
20181016Linux系统编程视频课程为《Linux系统编程》入门篇，主要针对零基础的Linux开发学员科普Linux系统编程的概念以及需要掌握的各种技能，掌握Linux命令编写、Linux学习路线并熟悉嵌入式设备编程的方法。为后续的Linux系统编程深入学习打下良好的基础。
手把手带你学会Python
20200303当下最火的计算机语言，难道你还只停留知道的阶段吗？快跟着老司机一起起飞吧~ 零基础开始学，只要跟着视频一步一步来，多思考，多练习，我相信你会有质的飞越。 学习路上会很苦，也会很累。但是这些等你学会以后，会发现这些都是值得。 还在等什么？快来学习吧~
 1.16MB
微信小程序 实例汇总 完整项目源代码
20161101微信小程序 实例汇总 完整项目源代码
Mysql数据库基础入门视频教程
20181024Mysql数据库基础入门视频课程：属于零基础Mysql数据库教程，从数据库的基本专业术语介绍到数据库软件的下载使用 一步一步带你安装MySql。SQL阶段你将学会如果使用数据定义语言DDL,数据操作语言DML,数据查询语言DQL 在学会各中查询语句之后,会带你学习数据的完整性, 掌握如果正确的向数据库中添加数据 以上掌握技能之后,将会带你学习如何进行多表操作,关系的建立,各种连接查询等. 常用函数,事务的学习,您将学到什么是事务的提交,回滚,并发操作及脏读,幻读. 最后视图,存储过程,索引的学习,将会带你掌握更高级的数据库技术.
Python进阶Pandas数据分析库
20181218您观看课程学习后 免费入群领取【超全Python资料包+17本学习电子书】 Pandas是python中非常常用的数据分析库，在数据分析，机器学习，深度学习等领域经常被使用。本课程会讲解到pandas中最核心的一些知识点，包括Series以及DataFrame的构建，赋值，操作，选择数据，合并等等，以及使用pandas对文件进行读取和写入，使用pandas绘图等等。
 65.8MB
java源码包java 源码 大量 实例
20130418Applet钢琴模拟程序java源码 2个目标文件，提供基本的音乐编辑功能。编辑音乐软件的朋友，这款实例会对你有所帮助。 Calendar万年历 1个目标文件 EJB 模拟银行ATM流程及操作源代码
 117B
Keil5安装包
20190523Keil5安装包，附带STM31F1、STM32F4支持包以及破解软件。
 1.42MB
TalentQ逻辑题
20200809自己用到，很有帮助，整理了一下，希望对大家有帮助
HoloLens2开发入门教程
20200501本课程为HoloLens2开发入门教程，讲解部署开发环境，安装VS2019，Unity版本，Windows SDK，创建Unity项目，讲解如何使用MRTK，编辑器模拟手势交互，打包VS工程并编译部署应用到HoloLens上等。
 82.2MB
微信小程序源码合集6.rar
20200904微信小程序源码，包含：图片展示、外卖点餐、小工具类、小游戏类、演绎博览、新闻资讯、医疗保健、艺术生活等源码。
 学院 PHP微信小程序服装购物商城大学生毕业设计教学视频
 下载 专用芯片技术中的AMD发布Radeon HD 7000M系列图形芯片
 下载 消费电子中的有没有一种技术可以提升智能手机的功耗性能？
 学院 2020年_Python_Django基础+实战全套视频【千锋】
 下载 Auto.js_3.1.0 Alpha6
 下载 工业电子中的触摸屏与PLC在捻线机自动控制系统中的应用
 下载 基于AVR单片机的多通道温湿度传感器检定系统
 下载 Art Lebedev 发布 Optimus Popularis 键盘价格，同时开始 Mini Six 预订
 下载 嵌入式系统/ARM技术中的基于Linux的串口服务器设计
 博客 Bochs一款可以跑电脑系统的app。
 博客 利用Django搭建一个简单Python Web项目！简单
 博客 一个有用的信号控制小程序
 学院 JavaWeb校园图书购物商城毕业设计 大学生毕业设计教学视频
 博客 VS2017/2019怎样配置第三方库才能不用每次新建项目都重新包含一遍？VS2017/2019怎样全局包含或添加第三方库？
 学院 基于RK3399和OpenCV实现实时视频增强
 下载 综合布线技术与经验总结
 学院 Docker/Kubernetes从理论到实战
 学院 PHP微信小程序鲜花礼品商城
 博客 getClassLoader()获取.properties路径问题
 下载 PHP实现的网站目录扫描索引工具
 学院 Windows脚本bat文件批处理基础教程
 学院 手把手教你手写Spring框架(附源码)
 学院 Java微信小程序鲜花礼品购物商城 大学生毕业设计教学视频
 下载 基础电子中的惠普HP NX7400笔记本电脑不触发
 博客 章柏幸需求的收敛过程UMLChina讲座音频和幻灯
 下载 LED照明中的采用电感的PWM调节方法
 学院 SkyEye智慧眼系统搭建 二
 下载 基于PCI总线的GPIB接口电路设计与实现
 博客 文件上传绕过技巧
 学院 项目管理工具箱