Summary 2113. "2016-12-17 universal group Simulation" Bracket problem (File IO): input:bracket.in output:bracket.out time limit: Ms Space limit: 2

Source: Internet
Author: User
Tags goto time limit two factor
2112. "2016-12-17 universal group simulation" Kinaka Canteen
(File IO): input:canteen.in output:canteen.out
Time limit: Ms Space limit: 262144 KB specific Restrictions Goto problemset Title DescriptionKinaka's canteen is very lively, of course it is crowded for the sake of (^__^). But Ji Middle school students are good children, will consciously lined up to play rice, and everyone to eat to consume time. In the K personal team, the first person to eat the time ti. Because each window can only serve a classmate at the same time, so the students in the back have to wait. On the day of the demonstration high school assessment, experts also came to the student cafeteria to eat. Before the experts came to the canteen, the students had already come to the canteen. In order to give experts to the Kinaka people have a good evaluation, the ranks of the students must let experts eat lunch as soon as possible (experts will certainly not cut the queue, and will not accept the comity of the students, they will wait in front of the students after the meal after the meal). People have a subjective understanding, experts feel waiting, is because all the students waiting for a long time, so the students wait for the sum of the smaller, the faster the experts eat rice.
Now your task is to determine the line-up plan that will allow the experts to eat food as soon as possible. inputThe first line, an integer K (1<=k<=300), indicates the number of students who are ranked among the experts.
After the second line is a K positive number, each line of 10 numbers for students from 1th to K of the meal time, T1,t2,...... Tk. (0<ti<=100000) OutputA line-up scheme that allows experts to eat food as soon as possible (data guarantees only one option), as long as the student's ordinal number (from the front of the queue to the last) is output. Sample Input
3
43.8 23.6 15
Sample Output
3 2 1
Data Range LimitsFor 30% of data,k<=100;
For 70% of data,k<=200;
For 100% of data, k<=300. 2113. "2016-12-17 universal group Simulation" bracket problem
(File IO): input:bracket.in output:bracket.out
Time limit: Ms Space limit: 262144 KB specific Restrictions Goto problemset Title DescriptionAs we all know, Kinaka's informatics competition is very strong. Experts to see if the Kinaka students are true, to a few of the junior students (of course, including the Informatics mavericks you) a few questions to test them. One of the problems is: the N-Number product k1k2 ... The KN inserts enough parentheses so that each product is exactly the product of a two factor. For example, K1K2K3K4 can be enclosed in parentheses:
((K1K2) (K3K4)) ((((K1K2) K3) K4) (K1 ((k2k3) K4)) ...
Changing the order of Ki is not allowed during parentheses. Now the expert wants you to tell him the total number of methods of legal parentheses. Because you have a great advantage in programming, other students recommend you to answer this question. In order to live up to the expectations of the students, but also to maintain the good reputation of the information group, you must answer this question well ...
inputAn integer K (2<=k<=30) OutputAn integer (number of methods) total. Sample Input
4
Sample Output
5
Data Range LimitsFor 40% of data,k<=10;
For 70% of data,k<=20;
For 100% of data, k<=30. 2114. "2016-12-17 universal group Simulation" Kinaka Day Tour
(File IO): input:tour.in output:tour.out
Time limit: Ms Space limit: 262144 KB specific Restrictions Goto problemset Title DescriptionAfter the evaluation of the demonstration high school, the experts thought Kinaka was too beautiful, too big, decided to visit Kinaka. But Kinaka campus is too complex, what Zhongshan Road, Qing-age road, Curtain Zhen Road and so on too many, so from the school gate to the new area of the route more than one or two. But experts ' time is valuable, especially not wasted. Now, the captain of the expert team has found you, and he has given you a table describing their chosen route (N*n's matrix A), allowing you to find the shortest route. The table shows the connectivity of any two intersections, as well as the distance. Matrix element A (I,J) =0 table is the intersection i,j is not connected, a (I,J)!=0 represents the driving distance of the intersection i,j. Which gate at intersection 1, new area at intersection N. inputFirst behavior a natural number n (1<n<=30);
then n rows, n integers per row, a table describing the route to be selected (the value of the element is less than 1000);
OutputThe first behavior is an integer that represents the distance of the shortest driving. Sample Input
4
0 2 3 4
2 0 1 1
3 1 0 0
4 1 0 0
Sample Output
3
Data Range LimitsFor 30% of data,n<=10;
For 70% of data,n<=20; For 100% of data, n<=30.
2115. "2016-12-17 universal group Simulation" Kinaka delivery Team
(File IO): input:queue.in output:queue.out
Time limit: Ms Space limit: 262144 KB specific Restrictions Goto problemset Title DescriptionThe evaluation is over, the tour is finished, finally to the farewell, in order to leave a good impression on the experts at the end, the information group of students formed a delivery team. After serious thinking, captain symbol decided to put the team in the K-column. In order to have a better visual effect, the number of people in each column is certainly not too different, but the aesthetic study shows that it is not the best visual effect when people are equal (indicating that any two columns cannot be equal). After careful deliberation, the captain thought that a formula could be used to describe the aesthetic value of a queueing method. Assuming value represents the size of the aesthetic value, then:
K
Value=∏wi =w1*w2*.....*wk
I=1
The greater the value, the better the visual effect.
Now the Expert Group is coming, but the notebook of symbol is broken. So he asked the students you programmed to help him find the best queuing method.
inputAn integer K with a population of M (1<=k<=50,m>=k* (k+1)/2), the data is guaranteed to have a solution. OutputOptimal queueing scheme: K-line numbers (small to large). Sample Input
3 7
Sample Output
1
2
4
Data Range LimitsFor 30% of data,k<=10,1<=m<=1300;
For 70% of data,k<=30,1<=m<=1300;
For 100% of data, k<=50,1<=m<=1300.

T1

Go ahead, and then mark the serial number.

T2

First divide n into two numbers (for example: 4=2+2, 1+3, 3+1), then multiply the scheme number of two numbers for each case, then add all the products together.

T3

Look for a minimum value greater than 1, then add up to a.

T4

First find out K. The value of the s=m-k!, and then from large to small sliding scale, add to S of 0.

Today is also a good state, got 100+100=200, the game did not come up with the 2nd, 4th, but good, continue to refuel.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.