50 The Machinegunners played home game, scored 0 goals, and conceded 0 goals. The Machinegunners played home game, scored 0 goals, and conceded 5 goals. The Machinegunners played home game, scored 0 goals, and conceded 15 goals. The Machinegunners played home game, scored 0 goals, and conceded 25 goals. The Machinegunners played home game, scored 0 goals, and conceded 30 goals. The Machinegunners played home game, scored 5 goals, and conceded 0 goals. The Machinegunners played home game, scored 5 goals, and conceded 5 goals. The Machinegunners played home game, scored 5 goals, and conceded 15 goals. The Machinegunners played home game, scored 5 goals, and conceded 25 goals. The Machinegunners played home game, scored 5 goals, and conceded 30 goals. The Machinegunners played home game, scored 15 goals, and conceded 0 goals. The Machinegunners played home game, scored 15 goals, and conceded 5 goals. The Machinegunners played home game, scored 15 goals, and conceded 15 goals. The Machinegunners played home game, scored 15 goals, and conceded 25 goals. The Machinegunners played home game, scored 15 goals, and conceded 30 goals. The Machinegunners played home game, scored 25 goals, and conceded 0 goals. The Machinegunners played home game, scored 25 goals, and conceded 5 goals. The Machinegunners played home game, scored 25 goals, and conceded 15 goals. The Machinegunners played home game, scored 25 goals, and conceded 25 goals. The Machinegunners played home game, scored 25 goals, and conceded 30 goals. The Machinegunners played home game, scored 30 goals, and conceded 0 goals. The Machinegunners played home game, scored 30 goals, and conceded 5 goals. The Machinegunners played home game, scored 30 goals, and conceded 15 goals. The Machinegunners played home game, scored 30 goals, and conceded 25 goals. The Machinegunners played home game, scored 30 goals, and conceded 30 goals. The Machinegunners played away game, scored 0 goals, and conceded 0 goals. The Machinegunners played away game, scored 0 goals, and conceded 5 goals. The Machinegunners played away game, scored 0 goals, and conceded 15 goals. The Machinegunners played away game, scored 0 goals, and conceded 25 goals. The Machinegunners played away game, scored 0 goals, and conceded 30 goals. The Machinegunners played away game, scored 5 goals, and conceded 0 goals. The Machinegunners played away game, scored 5 goals, and conceded 5 goals. The Machinegunners played away game, scored 5 goals, and conceded 15 goals. The Machinegunners played away game, scored 5 goals, and conceded 25 goals. The Machinegunners played away game, scored 5 goals, and conceded 30 goals. The Machinegunners played away game, scored 15 goals, and conceded 0 goals. The Machinegunners played away game, scored 15 goals, and conceded 5 goals. The Machinegunners played away game, scored 15 goals, and conceded 15 goals. The Machinegunners played away game, scored 15 goals, and conceded 25 goals. The Machinegunners played away game, scored 15 goals, and conceded 30 goals. The Machinegunners played away game, scored 25 goals, and conceded 0 goals. The Machinegunners played away game, scored 25 goals, and conceded 5 goals. The Machinegunners played away game, scored 25 goals, and conceded 15 goals. The Machinegunners played away game, scored 25 goals, and conceded 25 goals. The Machinegunners played away game, scored 25 goals, and conceded 30 goals. The Machinegunners played away game, scored 30 goals, and conceded 0 goals. The Machinegunners played away game, scored 30 goals, and conceded 5 goals. The Machinegunners played away game, scored 30 goals, and conceded 15 goals. The Machinegunners played away game, scored 30 goals, and conceded 25 goals. The Machinegunners played away game, scored 30 goals, and conceded 30 goals. Correct answers are: 1) 0 29 2) 5 30 3) 15 30 4) 25 30 5) 30 30 6) 0 24 7) 1 29 8) 11 30 9) 21 30 10) 26 30 11) 0 14 12) 0 19 13) 1 29 14) 11 30 15) 16 30 16) 0 4 17) 0 9 18) 0 19 19) 1 29 20) 6 30 21) 0 0 22) 0 5 23) 0 15 24) 0 25 25) 1 30 26) 0 30 27) 5 30 28) 15 30 29) 25 30 30) 30 30 31) 0 25 32) 0 30 33) 10 30 34) 20 30 35) 25 30 36) 0 15 37) 0 20 38) 0 30 39) 10 30 40) 15 30 41) 0 5 42) 0 10 43) 0 20 44) 0 30 45) 5 30 46) 0 0 47) 0 5 48) 0 15 49) 0 25 50) 0 30 More help: For Min, assume that opponents make 0 goals and they never win in random For Max, assume that opponents make 30 goals and they always win in random I don't understand where the error Two times I got for this problem the verdict "Time limit excceded 3" with time 0.031 and 0.015s respectively. What does it mean? Please answer,waht is the right answer for this text` The Machinegunners played away game, scored 0 goals, and conceded 0 goals. ? 0 30 Other tests 4 The Machinegunners played away game, scored 30 goals, and conceded 1 goals. The Machinegunners played away game, scored 30 goals, and conceded 30 goals. The Machinegunners played home game, scored 30 goals, and conceded 1 goals. The Machinegunners played home game, scored 30 goals, and conceded 30 goals. ans 0 1 0 30 0 1 1 30 Edited by author 08.06.2011 01:01 Edited by author 08.06.2011 01:01 Edited by author 14.07.2011 09:04 DELETED Edited by author 07.02.2011 23:41 I've got N*WA and AC today using simple searching algorithm.. Let's look on the condition: - the minimal number of goals they must score to get a chance to advance to the next round. So, in test: The Machinegunners played home game, scored 1 goals, and conceded 1 goals. I suppose that the first part of an example answer, 1 goal, isn't correct. Cause answer 0 goals also meet the condition. Why? Because if both teams will not score any goals, "Machines" will have have chance to advance to the next round at random. So, authors? btw, RUS and ENG texts are different in conditions: RUS (strong less): максимальное количество голов, которое они могут забить, не пройдя при этом в следующий раунд. ENG (less or equal): the maximal number of goals they may score which leaves a chance for their opponents to advance to the next round. So? no, because if they'll play 0-0 the number of goals scored by the second team in away match is 1, and Machines is 0, so the second team will go to the next round. It was mentioned in the task. Just write a function may_win and find min i \in [0,30] such that may_win(sc,co, i,0) "минимальное количество голов, которое они обязаны забить, чтобы получить шанс пройти в следующий раунд. максимальное количество голов, которое они могут забить, не пройдя при этом в следующий раунд." дак что всё-таки нада искать? минимальное кол-во голов, чтобы получить шанс или чтобы обязательно пройти и макс кол-во голов при котором не пройдут или могут не пройти? По-русски же написано. Минимальное количество голов, чтобы получить шанс; максимальное количество голов, при котором могут не пройти. Let's consider some cases: 1) the first part of the answer is a min number of goals needed to have a chance to advance next round. That means that the second team will score 0 goals in second game, and how many goals needed to be scored to complete the condition?? 2) the second part - max number of goals to be scored in such case, that the opposite team still will have a change to win. That means we must suppose second team to have scored 30 goals in second round. in each case we must calculate number of our scores to make the summarized scores equal for 2 rounds. But then we check the condition if the numbers of goals scored on the away fields of each team are equal - then the answer is OK, every team has a chance to advance. In first case we must take ++value of number if quantity of scored goals on away team is less (that means no chance), in second - value-- of number if quantity of scored goals on away team is greater(cause that leaves no chance for opposite team to win) is that enough to solve?? The Machinegunners played away game, scored 0 goals, and conceded 0 goals. The Machinegunners played away game, scored 15 goals, and conceded 15 goals. ans 0 30 0 30 Edited by author 02.11.2010 20:39 What is the answer for this tests? The Machinegunners played away game, scored 1 goals, and conceded 2 goals. The Machinegunners played home game, scored 0 goals, and conceded 1 goals. The Machinegunners played away game, scored 1 goals, and conceded 1 goals. Correct anwers are: 1 30 1 30 0 30 Для второго варианта почему мин = 1? При таком исходе получится, что нужно проводить жребий. У каждой команды будет по 1 очку, причем по одному на чужом поле... What is the answer for: The Machinegunners played away game, scored 30 goals, and conceded 0 goals. ? If they loose 0 : 30, they advance to the next round anyway, am I right? I was wrong and answer is 0 0 You should add this to get AC: if (ans < 0) ans = 0; if (ans > 30) ans = 30; How Machinegunners can get a chance to advance to the next round if they will score 0 goals at next tournament? So, second team can score 30 goals and second team will win! Where is a logic? How first num from answer can be little, than second. Explain plz. In first sample if they score 0 goals they will have a chance to win, because their opponents can score less than 30 goals (for example, 0) So, Machinegunners have a chance to win in this case (of course, not 100%, but it is not necessary, read problem's condition more carefully) Ok, for example: The Machinegunners played away game, scored 0 goals, and conceded 30 goals. In this case Machinegunners team has no chances to win! If in the home game the Machinegunners will score 30 goals and concede 0 goals then they will have chances to win. Что будет ответом на тест - The Machinegunners played home game, scored 0 goals, and conceded 30 goals. Спасибо. Не уверен, но если рассуждать так: при равных очках дома и в гостях и при равной сумме за два матча побеждает команда по рандому. Следовательно чтобы иметь шанс надо забить 30, но и при этом же победа не гарантируется. То есть 30 30. Edited by author 02.11.2010 21:17 |
|