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

Автор Kogut_Ivan, 12 месяцев назад, По-русски

Мы надеемся, что вам понравился контест! Спасибо вам за участие! Для нас это второй официальный раунд, поэтому мы были бы рады услышать ваши отзывы в комментариях и в мини опросе ниже.

Как вам контест?
Какие задачи вам понравились (можно выбрать несколько)?
Какие задачи вам не понравились (можно выбрать несколько)?

2132A - Домашнее задание

Идея: Wileyne; разработчик: Wileyne

Разбор
Решение

2132B - Загаданное число

Идея: fstilus; разработчик: fstilus

Подсказка
Разбор
Решение

2132C1 - Хитрый продавец (простая версия)

Идея: fstilus; разработчик: KotlechkovEgor

Подсказка 1
Подсказка 2
Подсказка 3
Разбор
Решение

2132C2 - Хитрый продавец (сложная версия)

Идея: Boodoochai; разработчик: KotlechkovEgor

Подсказка 1
Подсказка 2
Разбор
Решение

2132D - От 1 до бесконечности

Идея: fstilus; разработчик: fstilus

Подсказка 1
Подсказка 2
Разбор
Решение

2132E - Соревнование по арифметике

Идея: EzikBro; разработчик: EzikBro

Подсказка 1
Подсказка 2
Подсказка 3
Подсказка 4
Разбор
Решение 1
Решение 2

2132F - Рада и Ромашковая долина

Идея: Friendiks, Wileyne; разработчики: Friendiks, Wileyne

Подсказка 1
Подсказка 2
Подсказка 3
Подсказка 4
Разбор
Решение

2132G - Известный балетмейстер

Идея: fstilus; разработчики: fstilus, pskobx

Подсказка 1
Подсказка 2
Подсказка 3
Подсказка 4
Подсказка 5
Подсказка 6
Разбор
Решение
Разбор задач Codeforces Round 1043 (Div. 3)
  • Проголосовать: нравится
  • -133
  • Проголосовать: не нравится

»
12 месяцев назад, скрыть # |
Rev. 3  
Проголосовать: нравится 0 Проголосовать: не нравится

I found the solution for C2 1 minute after the contest ended! I am so sad :(

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Thanks for the fast editorial and the contest... very mathematical

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +17 Проголосовать: не нравится

Thank you for the contest! The problems felt very new and refreshing.

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

This contest is below the average not good and not bad.

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +4 Проголосовать: не нравится

Amazing contest! C2 was really fun.

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

My G is just Ctrl C + Ctrl V . ( I mean copying hashes) — My solution. Try to hack!

Sorry for my English)

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится -11 Проголосовать: не нравится

F is a piece of cake if you've solved this

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

F was easy but i just missed the output format:( i thought if there are no valid lanes then just output -1 and go for another testcase :sed:

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +15 Проголосовать: не нравится

Thank you for the contest ! , although I did unrated , but definitely one of my most favorite Div3's .

Kudos to authors.

»
12 месяцев назад, скрыть # |
Rev. 2  
Проголосовать: нравится 0 Проголосовать: не нравится

HELP

I did exact same thing as mentioned in editorial for problem F but it gives WA,any help is appreciated Kogut_Ivan .

Submission — 334939521

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

F was easy but i missed the output format i thought if there are no valid lanes then just output single line -1 and move for another testcase:(

»
12 месяцев назад, скрыть # |
Rev. 3  
Проголосовать: нравится +3 Проголосовать: не нравится

D is already online available: Geek for geeks cses

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

I am here after hearing that 2132E - Arithmetics Competition is practically equivalent to 2063D - Game With Triangles. As the coauthor of that problem, I must confirm that this is true. So you cannot fail to disappoint, huh...

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +23 Проголосовать: не нравится

I demand justice for ternary search solution for problem E! This problem is actually so fun to do ternary search with, as the moment you realize the function is linear brings so much satisfaction (from my 10-second long experience, it is indeed satisfactory)!

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +1 Проголосовать: не нравится

D is similar like digit queries of CSES problemset. I already solved digit queries still not able to solve the d problem sad :(

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +14 Проголосовать: не нравится

F was really amazing!

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +17 Проголосовать: не нравится

The problems were too mathematical and time consuming. Personally, I did not like the contest.

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Who is supposed to know or think this: If Vadim appends k zeros to the number x, what will be the ratio between n and x? I'm not doing math olympiad.

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +5 Проголосовать: не нравится

Math forces. I did e and f but not c2 and d, hope to see another div 3 soon ☺️

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Can someone explain why ternary search works in E but not binary search?

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +8 Проголосовать: не нравится

С2 is so nice

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +10 Проголосовать: не нравится

E and C2 are interesting!But I don't like D.

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Hello! If my rating is 1400 right now, what number of tasks in a contest should i ac so that it won't drop the rating? Thx

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +2 Проголосовать: не нравится

Simpler solution to D:

Binary search for the largest $$$L$$$ such that the total number of digits in $$$1, ..., L$$$ is at most $$$k$$$. Then, compute the sum of digits of all numbers in $$$1, ..., L$$$ as well as the partial piece of $$$L + 1$$$.

The number/sum of digits in $$${1, ..., N}$$$ are standard problems. The latter can be calculated via a digit-dp like approach.

Code: 334983266

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится +7 Проголосовать: не нравится

A good contest! I love it.

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Why should we do k /= 2 in C2 solution?

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Good C2 but bad F and G.

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Wileyne Note that this function is convex Isn't the function concave ?

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

In problem-C1, I found attached statement ambiguous

Statement

Which parameter should be minimized first? no of deals or cost

Because as per formula, cost(3^(x+1)) > cost(3*3^x)

Proof

This means if we increase no of deals cost will reduce but if we reduce no of deals cost will increase

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

    The statement, "considering that he will make the least possible number of deals", defines the number of deals explicitly. That is, you need to consider the minimum number of deals in general. From there, minimize the amount that will be paid.

    Note: The minimum number of deals is sum of digits in the base-3 representation of the given number.

»
12 месяцев назад, скрыть # |
Rev. 2  
Проголосовать: нравится 0 Проголосовать: не нравится

Why do I get Wrong Answer on test 97 when I submit the author's code (problem G)?

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

    Considering that the base set and modulo in the editorial's solution is fixed, I would guess that test 97 is a hack case.

    Random fact
»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Feels like I’m doing a math olympiad, not a Codeforces contest

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

great editorial!

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится
»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

F is such a great problem!! Loved it,although I have not read the tutorial yet but saw some solutions,I think everyone's doing the same thing as I did.

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

I think this one is not bad, but why are so many people against it? I think C2 and D are both pretty good.

:)

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

If a unimodal function has a flat top, can the ternary search algorithm be applied on the integer domain only if the flat top occurs at the extremum point? I used to think that if there was a flat top, the ternary search could not be used.

  • »
    »
    12 месяцев назад, скрыть # ^ |
    Rev. 3  
    Проголосовать: нравится +3 Проголосовать: не нравится

    It can be applied to that along with a few other forms of unimodal integer functions. You can search a unimodal integer function so long as it has strict inequality on one end and loose inequality on the other. In other words, it must be in one of these forms:

    $$$f(1) \lt f(2) \lt \dots \lt f(k) \geq f(k+1) \geq f(k+2) \geq \dots$$$ $$$f(1) \leq f(2) \leq \dots \leq f(k) \gt f(k+1) \gt f(k+2) \gt \dots$$$ $$$f(1) \gt f(2) \gt \dots \gt f(k) \leq f(k+1) \leq f(k+2) \leq \dots$$$ $$$f(1) \geq f(2) \geq \dots \geq f(k) \lt f(k+1) \lt f(k+2) \lt \dots$$$

    If we were to allow loose inequality on both ends, then getting the same value twice wouldn't tell us where we are relative to the maximum/minimum (whereas allowing it on strictly one end tells us that we are currently still on the same side of the maximum/minimum so long as we are comparing two consecutive spots during the ternary search). An example of an implementation which supports the aforementioned ternary search property can be found on kactl.

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

I just found out that there is something wrong with the problem B, why is it so? after I spent a lot of time solving problem B then I just read the solution from the editorial I just wrote the same way only and the answer is accepted, but here is my custom testcase why I found wrong, consider n = 123123, then the answer according to the editorial is 2 123 11193

so, is this solution right or wrong?, I feel sorry for those who wasted time on solution B

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

problem is mistaken

»
12 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

In problem E, the writer says "This will be the optimal answer because all the cards taken from array a will be at least as large as all the cards that have not yet been taken from array b , meaning there is no point in making additional swaps of cards from one array to another." Can any explain this? I don't understand.

»
11 месяцев назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Alright how the hell is this a div 3 competition?

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

why so many downvotes?