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

Автор flamestorm, 2 года назад, По-английски

Hej, Codeforces!

mesanu, SlavicG and I are very excited to invite you to Codeforces Round 937 (Div. 4)! It starts on Mar/28/2024 17:45 (Moscow time).

The format of the event will be identical to Div. 3 rounds:

  • 5-8 tasks;
  • ICPC rules with a penalty of 10 minutes for an incorrect submission;
  • 12-hour phase of open hacks after the end of the round (hacks do not give additional points)
  • after the end of the open hacking phase, all solutions will be tested on the updated set of tests, and the ratings recalculated
  • by default, only "trusted" participants are shown in the results table (but the rating will be recalculated for all with initial ratings less than 1400 or you are an unrated participant/newcomer).

We urge participants whose rating is 1400+ not to register new accounts for the purpose of narcissism but to take part unofficially. Please do not spoil the contest for the official participants.

Only trusted participants of the fourth division will be included in the official standings table. This is a forced measure for combating unsporting behavior. To qualify as a trusted participant of the fourth division, you must:

  • take part in at least five rated rounds (and solve at least one problem in each of them),
  • do not have a point of 1400 or higher in the rating.

Regardless of whether you are a trusted participant of the fourth division or not, if your rating is less than 1400 (or you are a newcomer/unrated), then the round will be rated for you.

Thanks a lot to the testers: erekle, vladmart, nika-skybytska, Vladosiya, KrowSavcik, Dominater069, LucaLucaM, MADE_IN_HEAVEN, tvladm, nor.

We suggest reading all of the problems and hope you will find them interesting. Good luck!

UPD: The round is delayed by 10 minutes: https://mirror.codeforces.com/blog/entry/127616?#comment-1133556.

UPD: The editorial is posted!

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

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

i wish i could solve all problems glhf

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

Why no green/cyan testers in Div4 round?

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

Hope everything goes OK!

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

Ramadan Kareem

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

Div 4 : The format of the event will be identical to Div. 3 rounds Div 3 : The format of the event will be identical to Edu rounds Edu rounds: The format of the event will be identical to Icpc rules

Is that a recursion?

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

Hope it isn't a div2.5 as last time

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

Ladies and gentlemen, finally I can say what I've always wanted to say at Div. 4 rounds announcements: My first unrated contest :")

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

please be a div 4 contest for div 4 people

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

Hopefully, My last rated div4

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

Hope efforts pay and this will be my last rated div 4

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

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

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

Hope to become Pupil with this contest :D

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

where are "one refresh costed me 10 minutes" comments?

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

Sorry, but I'm moving the round 10 minutes forward. The training session was very cool and long. I'm running to you from the gym!

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

The contest is delayed?

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

Hey guys, anyone have the problems for this div 4 so I can practice beforehand?

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

queueforces ?

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

Seems like div5

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

nice problem set , thanks to the authors

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

It's fun that due to the long queueforces (and my own laziness to open a proper local IDE) I would actually submit all problems in blind and fix them accordingly after every CE/WA/RTE/TLE/MLE...

What was I doing with my life...
Thoughts on problems
Hints on problems
»
2 года назад, скрыть # |
 
Проголосовать: нравится +17 Проголосовать: не нравится

How to do F in one line

Spoiler

Looks pretty weird but got AC by the way =))

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

    can you explain furtherly the thought process behind that?

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

      Basically the construction idea is identical to the editorial, so you should read it first. I will summarize a little bit.

      If a does not equal to c — 1, then there is no answer. Otherwise, we will build a full binary tree from top to bottom, using the nodes 2 and nodes 1. The height of this tree is p = ceil(log2(c)). After that we will calculate the number of "missing" nodes in the last level of the tree. It will be $$$2^p - c$$$. Finally, we will add the nodes 1 into the last level of the tree, level by level, as it will minimize the height of the tree.

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

Fast tutorial

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

do I have to participate in 5 contests to receive a rating? do all 5 contests have to be div.4??

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

A -> just do what is asked ( i had 1 wrong submission in it, forgot take input a , b , c ;( )

B -> just do what is asked pattern printing

C -> standard question leetcode style

D -> here i generated all the possible product possible, then counted whether they exist in my set or not

E -> string hashing to check wether string are equal or not ( wasted lot of time in implementing string hasing i am stupid )

F -> ran out of time

G -> ran out of time

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

Why does these 253813411 gets tle even though it looks to me as O(n*2^n)

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

Good competition! Thanks flamestorm,mesanu, SlavicG, and the testers :)

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

interesting round and one of the best div 4's,keep it up.

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

Who approved g? Why?

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

Wasted a lot of time in a dsu/graph-based solution in G, when it was such a straight bitmask dp :/ pain

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

about F, the only case answer -1 is c != a + 1 right...?

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

Good round, thanks mesanu SlavicG flamestorm and all testers.

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

in F can anyone explain the -1 case

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

    Initially there is one spot for a leaf. Adding type A vertex takes a spot for leaf, but creates two more (+1). Adding type B vertex takes a spot for leaf and makes one (+0). Adding type C vertex takes a spot for leaf (-1). All leaf spots should be taken so there is $$$1+a-c = 0\rightarrow a+1=c$$$.

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

      Right. Another way to see this is — for it to be a valid tree, number of edges should be equal to the number of vertices — 1, by definition. Hence,

      2 * a + b = a + b + c — 1

      a + 1 = c

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

Good round!

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

Here's my live coding + commentary during the above contest: https://www.youtube.com/watch?v=kQOWiTvgah0

Would be glad if some of you find it beneficial!

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

My submission 253708600 for E was hacked.

Can someone hack these as well:

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

I request to disqualify the competition because they included the name "Taylor Swift" in the test cases :-)

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

Когда рейтинг обновят

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

Happy to finally get in DIV4 rounds :), and finally promoting to pupil. The problems were nice, sadly I had not beeing able to finish all 7 as I used to much time for E. Thanks to the writers and testers for creating this beautiful round.

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

Does code force hack by someone yesterday I successfully submit 3 questions and accept all but few moments ego it not show any questions submitted and suddenly showing only one question submitted why this happened does this happen with only everyone facing this issue and not get any rating yet

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

I had only 5 jugs of lassi this time..... In next contest I will be mango lassi.... be tuned to see me there as well.

Yours Lovely Kesar Lassi

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

CONGRATULATIONS the system testing took forever

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

is this contest made unrated? Why it is showing unrated in my profile although I am having rating less than 1400

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

when will the ranks get updated? I was 600+, solved two problems. Shouldn't my rank be changed?

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

When will ratings be updated?

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

I think there is a bug with people rating changes for this contest

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

Are you OK? This f**k E, I use map get TLE, but use unordered_map or add a return get AC, just because constant. This solution is like n*sqrt(n), why just give 1s?

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

mesanu SlavicG I got a mail stating:- Your solution 253808750 for the problem 1950E significantly coincides with solutions SahooBishwajeet/253808750, candidate_3_months/253813331.

I checked the solution comparison and most of the common part was use of same #defines and variable initialization. Though the approach looks quite similar, which is to my surprise, I can assure you that I've not cheated in any form. I've followed an article on GeeksForGeeks which has a similar problem to solve the problem in the contest.

The problem approach is quite similar to the problem : https://www.geeksforgeeks.org/find-given-string-can-represented-substring-iterating-substring-n-times/

Please check the issue as I've not used any unfair means during the contest period and honestly gave the contest.

 https://pasteboard.co/cdhdULYYUpns.png  https://pasteboard.co/c8TFSsNWtA4b.png

Here are the comparison images for reference

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

Пользователь Alfar_ABI уже написал о том что произошло и как так вышло что коды получились похожими