Блог пользователя numbertheorist17

Автор numbertheorist17, история, 8 лет назад, По-английски

Hello, Codeforces!

I am happy to announce Codeforces Round #331 (Div. 2)! The round will be held on November 15th at 7:35 MSK. Div. 1 users can participate out of contest.

The problem set was prepared by me (Girishvar Venkat) and jaina (Jeffrey Zhang). I sincerely thank GlebsHP (Gleb Evstropov) for helping with the preparations of the contest. I also thank thesilione (Bili Sun) for testing this round.

The hero for this round will be Wilbur the pig, after my good friend wilbs43 (Wilbur Li).

Scoring will be 500-1000-1500-2250-2500.

Hope you enjoy this round and wish you high rating!

UPD: Contest is over. Here is a link to editorial: Editorial.

UPD2: Congratulations to all the winners! Results:

Div. 1:

  1. tourist

  2. DBradac

  3. ztxz16

  4. V--o_o--V

  5. waterfalls

Div. 2:

  1. Ichiban

  2. Antoniuk

  3. thjchph4trjnh

  4. halyavin

  5. Rafiki53

Hope you all enjoyed this contest! Thanks for participating!

UPD3: Ratings updated.

  • Проголосовать: нравится
  • +309
  • Проголосовать: не нравится

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by numbertheorist17 (previous revision, new revision, compare).

»
8 лет назад, # |
  Проголосовать: нравится +57 Проголосовать: не нравится

It's very rare that scoring distribution isn't "announced later".

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится +2 Проголосовать: не нравится

    Don't understand what is the profit of knowing the scroring distribution before contest. Almost all participants solve tasks starting from the most easy (= problem A).

»
8 лет назад, # |
  Проголосовать: нравится +14 Проголосовать: не нравится

lots of number theory problems ?!?! :)

»
8 лет назад, # |
  Проголосовать: нравится +15 Проголосовать: не нравится

I wonder why it's 19:35 but not 19:30.

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится +5 Проголосовать: не нравится

    I think the 5 minutes difference is just that famous DELAY!!

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится +178 Проголосовать: не нравится

    We found that in case of 5-10 minutes delay there are many participants who additionally register. It seems it is some kind of psychology: if you see that round will start on 19:30 (and even if you know about 19:25 as deadline for registration), your brain rounds 19:25 to 19:30 and probably you will be near your computer on 19:30, but not on 19:25.

»
8 лет назад, # |
  Проголосовать: нравится -32 Проголосовать: не нравится

Is round going to be interesting ? Your color says the contest not going to be interesting. Always people with color like your's make contest hard and uninteresing.

»
8 лет назад, # |
Rev. 2   Проголосовать: нравится +7 Проголосовать: не нравится

as your username it seems we are going to have number theory problems

»
8 лет назад, # |
  Проголосовать: нравится +49 Проголосовать: не нравится

I know I'm gonna get many downvotes for this comment, but I really hope that problems would be based more on complex algorithms rather than math.

»
8 лет назад, # |
  Проголосовать: нравится +2 Проголосовать: не нравится

this contest will be rated! yeeee! ^_^

»
8 лет назад, # |
  Проголосовать: нравится +11 Проголосовать: не нравится

I thought I saw Xellos comment in this thread, but now it's disappear. Is that a bug?

»
8 лет назад, # |
  Проголосовать: нравится -28 Проголосовать: не нравится

I think its going to be a math contest (The handle of Girishvar Venkat :|) Why not changing the name from CodeForces 2 AlgebraForces??

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Did you create a new account for writing this comment? Why are you so afraid of using your original account if you are really thinking this way?

»
8 лет назад, # |
  Проголосовать: нравится +11 Проголосовать: не нравится

Wish I can have a good night and a high rating.

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Hope for maths!

»
8 лет назад, # |
  Проголосовать: нравится +2 Проголосовать: не нравится

just a usual delay !!!

»
8 лет назад, # |
  Проголосовать: нравится -7 Проголосовать: не нравится

Mathforces instead of codeforces ...

»
8 лет назад, # |
  Проголосовать: нравится +6 Проголосовать: не нравится

Really liked the problems! Haven't had such a nice round for a while

»
8 лет назад, # |
  Проголосовать: нравится +1 Проголосовать: не нравится

Can anyone explain C?

  • »
    »
    8 лет назад, # ^ |
    Rev. 22   Проголосовать: нравится +46 Проголосовать: не нравится

    I've come up with the following idea:

    As you can see, we can associate a list of vertices with an index of an array (or map, if you will).

    Step 1: create the vertex queues

    Vertices on the diagonal (0, 0), (1, 1), (2, 2), (3, 3), (4, 4), ... are all map to 0. That means, we can store these particular vertices under the key 0 in some container. I store them like that:

    map< vector< pair<int, int> > > vertex_queues;
    vertex_queues[0].push_back( make_pair(1, 1) );
    vertex_queues[0].push_back( make_pair(3, 3) );
    vertex_queues[0].push_back( make_pair(2, 2) );
    ...
    

    vertex_queues[0] now stores the vertices unordered. So, we need to sort them so that we can use them later.

    Step 2: construct the answer by taking the vertices from the vertex queues in the right order

    The last step is building the answer. We go through the array w[n] from left to right and take the first element from the vertex queue with the index w[i]. So, the i'th vertex must be the one we've just taken from the queue. One by one, we extract all the vertices from the vertex queues in the order dictated by the array w[n].

    If there are no elements in the w[i]'th vertex queue, the anser is NO. If, lastly, we look though all the vertices in the array that we've constructed and find that the current vertex is less than the previous one, the answer is also NO.

    Otherwise, we've build the perfectly valid array of vertices which is the solution to the problem :)

    14288949 — with map
    14289137 — with vector

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится +4 Проголосовать: не нравится

    First you should sort points by their y-x then for each w[i] from last to first set the point with biggest x and y!

    now we should check that does this greedy algorithm make a aesthetically pleasant! sort points and then for each (x,y) we calculate the mp[ (x,y) ] the maximum index of every point like x' and y' that 0<=x'<=x and 0<=y'<=y in the answer! and we update it with mp[ (x-1,y) ] and mp[ (x,y-1) ] , if one of them was bigger than index of (x,y) print No!

    now we know answer for each w[i] and it's aesthetically pleasant!

»
8 лет назад, # |
Rev. 2   Проголосовать: нравится +8 Проголосовать: не нравится

А RuntimeError на кф уже не учитывают? Вот Код человека и тест который я вбил. Мне сообщило что у него выводит -1 и все ок. Скажите мне факт которого я не знаю, чтобы я больше не делал глупых взломов.

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    UB в C++ — вещь непредсказуемая. Могло и нормально отработать.

»
8 лет назад, # |
  Проголосовать: нравится +3 Проголосовать: не нравится

Auto comment: topic has been updated by numbertheorist17 (previous revision, new revision, compare).

»
8 лет назад, # |
  Проголосовать: нравится +5 Проголосовать: не нравится

Editorial before finish time ??

»
8 лет назад, # |
Rev. 3   Проголосовать: нравится +2 Проголосовать: не нравится

hacked 5 people in problem B in my first hacking attempt on codeforces thanks to this

2

-1000000000 1000000000

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    I also wanted to have my first hacking attempt with such a silly mistake, that I also had made, but I had not found in time where the hacking button is, what a shame...

    • »
      »
      »
      8 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится

      go to room than double click in any submission and hack it , of course you have to lock your problem .

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится +9 Проголосовать: не нравится

    Nobody in my room was stupid enough not to use long long.

»
8 лет назад, # |
  Проголосовать: нравится -7 Проголосовать: не нравится

The character "Wilbur" may just as well have not been in the problem statements. All it did was add clutter.

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится +18 Проголосовать: не нравится

    But reading the problem through the clutter is a part of the problem. If you would be said like "given array, find sum of absolute differences between i and i+1 for i from 0 to N-1" then it wouldn't be a contest.

    • »
      »
      »
      8 лет назад, # ^ |
        Проголосовать: нравится -23 Проголосовать: не нравится

      The clutter I'm talking about is the crap about Wilbur, not the actual problem itself. The problem could have been simply:

      You are given an array a of size n which initially consists of all zeroes. In one step, you may choose any index i and either add or subtract 1 to all elements from ai to an. Your goal is to end up with the given array b.

      What is the minimum number of steps required to reach your goal?

      Simple and concise. Add a story behind it if you'd like, but don't do it just for the sake of doing it.

    • »
      »
      »
      8 лет назад, # ^ |
      Rev. 2   Проголосовать: нравится +9 Проголосовать: не нравится

      It's a trade-off. The problems on Project Euler don't have stories, but that doesn't make them any more boring for me. Personally I actually prefer that approach, but I'm also fine with some characters and a small story to make the problems more fun.

      The thing with Codeforces is that the English is very difficult to read and often has typos or grammatical mistakes. And sometimes there's just so much stuff. See this older problem for example, would you enjoy reading that when there's pressure to solve the problem in 2-3 minutes? http://codeforces.com/problemset/problem/48/A

»
8 лет назад, # |
  Проголосовать: нравится +56 Проголосовать: не нравится

I loved the contest — keep it up! Thanks numbertheorist17 and GlebsHP

»
8 лет назад, # |
Rev. 5   Проголосовать: нравится +33 Проголосовать: не нравится

Самый лучший контест!

Без непредвиденных задержек, с разбором сразу же после окончания, и систесты тоже быстро начались! Рейтинг тоже быстро обновили.

Побольше бы таких :)

Кстати, между окончанием контеста и окончанием систестов прошло менее 20 минут :)

Большое спасибо numbertheorist17!

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Еще бы русский разбор и вообще отлично...

»
8 лет назад, # |
Rev. 2   Проголосовать: нравится +1 Проголосовать: не нравится

This comment was written before final results. I didn't know that they will be same

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Problem E was nice but pretty hard to implement in a short time,it would have been better if the input was a tree instead of matrix(because it wouldn't have cycles and make things easier)

»
8 лет назад, # |
Rev. 2   Проголосовать: нравится +3 Проголосовать: не нравится

Super fast system testing this time

»
8 лет назад, # |
  Проголосовать: нравится -14 Проголосовать: не нравится

Почему в задаче А тест

3
1 1
2 2
5 5

некорректен?

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится +9 Проголосовать: не нравится

    эти точки не являются вершинами прямоугольника положительной площади, у которого стороны параллельны осям.

    • »
      »
      »
      8 лет назад, # ^ |
        Проголосовать: нравится -14 Проголосовать: не нравится

      Но ведь любая точка является вершиной какого-то прямоугольника положительной площади, более того, таких прямоугольников бесконечно много.

      • »
        »
        »
        »
        8 лет назад, # ^ |
          Проголосовать: нравится +5 Проголосовать: не нравится

        Они должны быть вершинами одного прямоугольника.

        • »
          »
          »
          »
          »
          8 лет назад, # ^ |
            Проголосовать: нравится -22 Проголосовать: не нравится

          Кому должны? Не вижу этого в описании входных данных, покажите.

      • »
        »
        »
        »
        8 лет назад, # ^ |
          Проголосовать: нравится +3 Проголосовать: не нравится

        Они вместе должны образовывать прямоугольник, а не каждая точка по отдельности. Прямоугольника с вашими вершинами не существует.

        • »
          »
          »
          »
          »
          8 лет назад, # ^ |
            Проголосовать: нравится 0 Проголосовать: не нравится

          Покажите, где это написано в описании задачи.

          • »
            »
            »
            »
            »
            »
            8 лет назад, # ^ |
            Rev. 2   Проголосовать: нравится +20 Проголосовать: не нравится

            Он ввёл координатные оси и так выбрал прямоугольник, чтобы его стороны были параллельны этим осям. Конечно, площадь этого прямоугольника была положительна. Все четыре вершины запланированного бассейна были записаны у Вилбура на бумажке, пока не пришёл его вредный друг и не стёр некоторые вершины.

            Вам во входных данных даются вершины, не стёртые его другом.

            Гарантируется, что точки яляются вершинами какого-то прямоугольника положительной площади, со сторонами параллельными осям координат.

            ___ Либо я не понимаю, как вы стали синим, либо вы очень любите придираться к словам не по делу.

            • »
              »
              »
              »
              »
              »
              »
              8 лет назад, # ^ |
                Проголосовать: нравится -19 Проголосовать: не нравится

              Вилбур мог ошибиться при записывании координат на бумажку, не зря же он сиеновый на кодфорсе. :)

              Фраза "Гарантируется, что точки яляются вершинами какого-то прямоугольника положительной площади, со сторонами параллельными осям координат." в прямоугольной системе координат бессмысленна. Очень странно видеть ее в контесте, в котором есть задача на математическое ожидание.

              А про то, как я стал синим, — ребята, не стоит вскрывать эту тему.

              • »
                »
                »
                »
                »
                »
                »
                »
                8 лет назад, # ^ |
                  Проголосовать: нравится +15 Проголосовать: не нравится

                Всё-таки, с точки зрения русского языка, фраза "точки являются вершинами прямоугольника" говорит как раз о том, что точек много, а прямоугольник один. В противном случае правильно было бы сказать "Гарантируется, что точки являются вершинами каких-то прямоугольников..." и, действительно, не имела бы смысла.

»
8 лет назад, # |
Rev. 4   Проголосовать: нравится +98 Проголосовать: не нравится

> when you hack someone and then fail on your own hack during systest

EDIT: The funny thing is, if I hardcode the answer to my hack test, I get AC. Meaning if I didn't hack, maybe I wouldn't have failed systest... worst feeling ever :'(

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

I don't know how to deal with the problem D? Is this a dp problem?

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Seems like it. dp[left/right][start][end] precompute two arrays to determine the first tree that will be available to cut if ith tree is cut and falls on left, and right respectively.

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by numbertheorist17 (previous revision, new revision, compare).

»
8 лет назад, # |
  Проголосовать: нравится +4 Проголосовать: не нравится

What a bad day! I did my computer component principle homework about how cpu work the whole day and didn't finish it. That made me not think strictly in round and get a bad rank. I'm so sad. :(

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by numbertheorist17 (previous revision, new revision, compare).

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

why the main test 18 in problem A gives wrong answer but when i run this program in my ide it give me correct answer 0

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    The correct answer for that test is 227504, and yours is 0

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Correct answer isn't 0. Its 227504. I failed at the same due to a stupid mistake. Should have tested more rather then racing against time.

»
8 лет назад, # |
  Проголосовать: нравится +1 Проголосовать: не нравится

Обнаружил баг/фичу: когда сначала во взломе выбираешь в ручном режите файл, случайно, потом переходишь на генерируемый крепишь код жмешь отправить пишеет странные ошибки типа выберите файл Потратил пару минут чтобы вкурить и перегрузить Спасибо

»
8 лет назад, # |
  Проголосовать: нравится +37 Проголосовать: не нравится

tourist is BACK for a contest! :D

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится -30 Проголосовать: не нравится

    Maybe he decided that Div.1 contests are too complicated for him and will participate only in Div.2?

    • »
      »
      »
      8 лет назад, # ^ |
        Проголосовать: нравится +7 Проголосовать: не нравится

      you must be kidding.

      • »
        »
        »
        »
        8 лет назад, # ^ |
          Проголосовать: нравится -9 Проголосовать: не нравится

        Ofc no. I was just trying to figure out, why hadn't he taken part in theeeeeeese Div.1 contests instead of boasting in front of Div.2 users? The answer was quite evident.

»
8 лет назад, # |
  Проголосовать: нравится +3 Проголосовать: не нравится

Why this code getting TLE? Its complexity is O(n^2) :( I really don't have any idea why.

14287878

»
8 лет назад, # |
Rev. 2   Проголосовать: нравится +12 Проголосовать: не нравится

Weak Test cases in C.
8 0 0 0 1 0 2 1 0 1 1 1 2 2 0 2 1 0 1 2 -1 0 1 -1 -2
Solutions giving YES followed by wrong sequence gets AC.
Correct Answer: NO
AC Buggy code: 14287550

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

We always see in codeforces, the output is judged by special judge. that means if the output is 1 then if you print 1.000 there is no problem. Even sometimes Lower case uppercase does not matter. Today I wrote problem A with double variable got WA. For output printing the problem says, "Print the area of the initial rectangle if it could be uniquely determined by the points remaining. Otherwise, print  - 1." There is no instruction that the output should be integer. But it causes me wrong answer and finally I have a devastating contest. 14274647

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Your answer does not actually specify the last significant digit of the answer

    • »
      »
      »
      8 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится

      Thanks, I get it. It's my fault not to specify the setprecision. Default setprecision causes the error.

»
8 лет назад, # |
  Проголосовать: нравится +10 Проголосовать: не нравится

Could someone explain me how this solution (http://codeforces.com/contest/596/submission/14278463) passed all tests?!

P.S.: during the contest I tried to hack it several times using tests like

but without any success :(

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Thats strange. Even the basic test such as "1 1000000000" runs forever on my computer. Are there any kind of optimizations being done in codeforces compiler?

    • »
      »
      »
      8 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится

      I believe so. There has been a blog about this kind of thing before.

    • »
      »
      »
      8 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится

      Codeforces compiles C++ with gcc's -O2 flag, which is really common among a lot of online judges and other competition platforms.

  • »
    »
    8 лет назад, # ^ |
    Rev. 2   Проголосовать: нравится +29 Проголосовать: не нравится

    C++ Optimizer. Optimizer is much smarter than that programmer.

    • »
      »
      »
      8 лет назад, # ^ |
      Rev. 3   Проголосовать: нравится +1 Проголосовать: не нравится

      Absolutely agree :)

      So why not to disable C++ compiler optimizations on Codeforces? Because now hacking such cases is just like trying your luck :(

      • »
        »
        »
        »
        8 лет назад, # ^ |
        Rev. 2   Проголосовать: нравится +7 Проголосовать: не нравится

        Because it would be unfair if you keep in mind almost all compilers/interpreters do it (Codeforces supports a lot of languages!).

        Anyways: gcc's -O2 flag is used almost everywhere in competitive programming, and while optimizations like this one tend to obscure the true meaning of the code, they only happen in specific situations and do more good than harm.

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by numbertheorist17 (previous revision, new revision, compare).

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Very Weak Data Set for problem C ... http://codeforces.com/contest/596/submission/14281582 3 6 3 7 0 6 2 -3 -7 -4 This code cant pass this input, but passed system test.

  • »
    »
    8 лет назад, # ^ |
    Rev. 2   Проголосовать: нравится +4 Проголосовать: не нравится

    Your input:

    3
    6 3
    7 0
    6 2
    -3 -7 -4
    

    is not valid, is it? Take a closer look to the input section of problem C.

  • »
    »
    8 лет назад, # ^ |
    Rev. 2   Проголосовать: нравится +3 Проголосовать: не нравится

    "Also, it is guaranteed that if some point (x, y) is present in the input, then all points (x', y'), such that 0 ≤ x' ≤ x and 0 ≤ y' ≤ y, are also present in the input."

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Why I got verdict skipped? 14275850, 14282184 and 14273892. This is my first time to solve 3 problems in a contest!

»
8 лет назад, # |
Rev. 2   Проголосовать: нравится +24 Проголосовать: не нравится

tourist was the first to solve each problem , amazing !!

»
8 лет назад, # |
Rev. 2   Проголосовать: нравится +14 Проголосовать: не нравится

numbertheorist17

Weak Test cases in Question: C. input: 15 0 0 1 1 2 2 0 1 1 2 2 3 0 2 1 3 0 3 0 4 1 0 2 1 2 0 3 1 3 0 0 1 -1 2 0 -2 3 1 -1 -3 2 -2 1 4 0

output: should be NO [also verified using [user:tourist] sol'n :p]

Two users in top5(div2 rankings) got it accepted...even though their output is wrong.
Rank1: Ichiban and Rank5: Rafiki53 :p

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Also my solution verify this :D (I'm 99.00% sure about my solution correctness)

  • »
    »
    8 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    This is unfortunate. I thought I took care of all the cases, but I guess I didn't. Sorry about that! Next time, I will have to be more careful.

    • »
      »
      »
      8 лет назад, # ^ |
        Проголосовать: нравится +3 Проголосовать: не нравится

      Less than 1% of div2 participants solved D and less than 0.1% solved E.

      Is this the expected difficulty level to make participating fun for div1 people too? Or maybe it would be more fun for div2 people if they could get more than 3/5 once in a while?

      • »
        »
        »
        »
        8 лет назад, # ^ |
          Проголосовать: нравится +5 Проголосовать: не нравится

        I think it is just that jaina and I thought the problems are easier than they actually are.

        • »
          »
          »
          »
          »
          8 лет назад, # ^ |
            Проголосовать: нравится 0 Проголосовать: не нравится

          Fair enough. :)

          I understand that estimating the difficulty must be very hard.

          If you'd like to get feedback for future problems from someone who's far from div1 level, I'd like to volunteer. Maybe sometimes it would be possible to add some simple problems and hold a div1 and div2 at the same time, making everybody happy!

  • »
    »
    8 лет назад, # ^ |
    Rev. 2   Проголосовать: нравится 0 Проголосовать: не нравится

    MikeMirzayanov, GlebsHP take a look please

    • »
      »
      »
      8 лет назад, # ^ |
        Проголосовать: нравится +3 Проголосовать: не нравится

      The testset for this problem turned out to be weak. That happens sometimes, but everyone is free to do challenges and improve it during the contest.

»
8 лет назад, # |
  Проголосовать: нравится +22 Проголосовать: не нравится

»
8 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Who else thinks D was more doable than C?

  • »
    »
    8 лет назад, # ^ |
    Rev. 2   Проголосовать: нравится 0 Проголосовать: не нравится

    During the contest I got intimidated by the number of people who solved D and didn't give it much thought. Later I tried to solve it and found it easier than C either, it's a straight foward DP.

    Actually I think the hardest task on C was understand the english translation, the problem itself wasn't hard.

»
8 лет назад, # |
  Проголосовать: нравится +14 Проголосовать: не нравится

I Love Judge!!!???