YouKn0wWho's blog

By YouKn0wWho, 2 years ago, In English

UPD: (28 April, 2022)

Donated Finally

আবার চলে এসেছি! (That's Bengali for "I am back! (in Terminator mode)")

I am super excited to invite you to participate in Codeforces Round 752 (Div. 1) and Codeforces Round 752 (Div. 2) which will be held on Oct/30/2021 17:35 (Moscow time). This round is rated for both divisions.

You will be given $$$6$$$ problems in each division and $$$2$$$ hours to solve them. All the problems are authored and prepared by me.

I would like to thank -

The statements are short and directly ask you what to do and I have tried to make the pretests strong. I highly encourage you to read all the problems.

Solve problems and help the poor! Yes, you heard it right, this time you can help the world by just solving problems. I will donate money based on the solve count of each problem by the following measure:

Donation Per AC

The total estimated money is half of what I will get from Codeforces for this contest(but you can make it more by just solving more problems!). I am a student, so pardon me if that's too little.

Also, did you know that you can still upvote my The Ultimate Topic List blog and make it to the top?

Finally, I would like to dedicate this contest to me! I want to thank me for believing in me, for doing all this hard work, for trying to do more right than wrong. I want to thank me for just being me at all times.

Score distribution:
Div.1: $$$750-1000-1750-2500- 3500-3750$$$.
Div.2: $$$500-1000-1750-2000-2750-3500$$$.

Good Luck! Love you blobheart.

UPD: Editorial

UPD: Congratulations to the winners.

Div.1:

  1. tourist
  2. djq_cpp
  3. Petr
  4. gop2024
  5. ecnerwala

Div.2:

  1. Rolling_Code
  2. Pecans
  3. fangzhijina2020
  4. whtdsjmr
  5. Graphcities

UPD: Here is how the donation amount looks like:

Donation

FYI I will get 400 USD for this contest. So the donation amount is indeed half of this as I have estimated before the contest, although didn't think that it would be this accurate.

I will update you again when I get the money from Codeforces, more likely after a few months as I haven't received my previous contest's payment yet which happened 3 months ago!

Also, thanks for being a part of this. You have just helped someone who is in need (I mean after I distribute the money).

  • Vote: I like it
  • +3156
  • Vote: I do not like it

| Write comment?
»
2 years ago, # |
  Vote: I like it +103 Vote: I do not like it

Donation per AC!! Just loved it. Proud of you vai ♥

»
2 years ago, # |
  Vote: I like it +44 Vote: I do not like it

no funny text this time? :P

»
2 years ago, # |
  Vote: I like it -40 Vote: I do not like it

"0.005 USD" WOW THANKS MR.GENEROUS

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +9 Vote: I do not like it

    I see your negative comments almost in every recent blog posts. Seems like you have opened this account just to pass rude comments!

»
2 years ago, # |
  Vote: I like it +37 Vote: I do not like it

If someone can help the poor just by solving problem, that's gonna be more fun!! :D

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Yet another great round is coming ! :D

»
2 years ago, # |
  Vote: I like it +24 Vote: I do not like it

Great Initiative

»
2 years ago, # |
  Vote: I like it +20 Vote: I do not like it

That's great Shohag. Hope everyone will enjoy this contest.

»
2 years ago, # |
  Vote: I like it +11 Vote: I do not like it

Wow, that's great. Hats off to you.

»
2 years ago, # |
  Vote: I like it +11 Vote: I do not like it

Proud of you, bhai. <3

»
2 years ago, # |
  Vote: I like it +23 Vote: I do not like it

Super excited for a Bangladeshi round again!! :D

»
2 years ago, # |
  Vote: I like it +10 Vote: I do not like it

Very Good idea for helping poor people. Thanks for this contest. I am so happy that I can help poor people.

»
2 years ago, # |
Rev. 2   Vote: I like it +32 Vote: I do not like it

Hope for 2K upvotes and Rank #1 in top contributors.

»
2 years ago, # |
  Vote: I like it +130 Vote: I do not like it

:(

»
2 years ago, # |
  Vote: I like it +8 Vote: I do not like it

Inviting the fellow programmers to be the part of this initiative....

»
2 years ago, # |
Rev. 4   Vote: I like it +11 Vote: I do not like it

Let's send YouKn0wWho vai(brother) to the Mars by upvoting.

Spoiler
»
2 years ago, # |
Rev. 2   Vote: I like it +5 Vote: I do not like it

এভাবেই বারবার চলে আসবেন ভাই ♥♥

»
2 years ago, # |
  Vote: I like it +8 Vote: I do not like it

Very excited to praticipate of a bangladeshi round.

»
2 years ago, # |
  Vote: I like it +6 Vote: I do not like it

Donation per AC!! Too good to be true.

»
2 years ago, # |
Rev. 2   Vote: I like it +21 Vote: I do not like it

Again , pari na pari khela hobe :3 (it means i will must participate ,dont downvote)

»
2 years ago, # |
  Vote: I like it +11 Vote: I do not like it

Your last round was extremely good. I hope this one is as well.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    That was a tough Math round

    how many did you solve or you like the testcases

»
2 years ago, # |
  Vote: I like it +16 Vote: I do not like it

For a moment I thought why the blog has only 166 upvotes(previous round announcement has more than 1600) then I realized that you are back with a new round .

»
2 years ago, # |
  Vote: I like it +2 Vote: I do not like it

Really looking forward for this one after the last round. Also props on the idea for donations <3

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Super excited Vaia. Take Love.

»
2 years ago, # |
  Vote: I like it +61 Vote: I do not like it

Codeforces Round #752, writer: YouKn0wWho

Spoiler
»
2 years ago, # |
  Vote: I like it +31 Vote: I do not like it

As a tester, these are some of the coolest problems I've encountered in quite some time. So if you're going to participate, you're in for a treat!

»
2 years ago, # |
  Vote: I like it +55 Vote: I do not like it

as a tester, I would say the problems seemed very cool to me. don't dare to miss the contest and the potential high rating! Good LUCK all!

»
2 years ago, # |
  Vote: I like it +2 Vote: I do not like it

just curious.. how much does codeforces pay one for setting up a contest?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +24 Vote: I do not like it

    look at this
    This contest is Div1+2 then CF will pay 400 USD.

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +3 Vote: I do not like it

      Actually i was trying to estimate the total amount and it came up around 350+ dollars. Damn, i should have seen this comment from the start.

»
2 years ago, # |
Rev. 3   Vote: I like it +48 Vote: I do not like it
»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Hyped for more anime references in the questions lol

»
2 years ago, # |
  Vote: I like it +34 Vote: I do not like it

So if I participate from Div1 and solve all problems, you donate 6.255 USD, that's nice. But that's too tough, I'll just donate 7 USD myself instead.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +108 Vote: I do not like it

    I thought you stopped being a nerd.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +79 Vote: I do not like it

    Or better.. I'll donate 7 USD, so give me solutions to submit during contests. :catThink:

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it -40 Vote: I do not like it

      Okay this is bad, now we're plane selling and buying solutions.

      (give me some I'll give you 14 USD)

  • »
    »
    2 years ago, # ^ |
    Rev. 2   Vote: I like it -39 Vote: I do not like it

    Deleted

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +9 Vote: I do not like it

    good to see u back

»
2 years ago, # |
Rev. 2   Vote: I like it +241 Vote: I do not like it

dorijanlendvaj for providing a test case which will potentially prevent few wrong solutions from getting AC.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +34 Vote: I do not like it

    I don't have any say over whether it will be in pretests, YouKn0wWho just asked "Is there a test case that accomplishes [REDACTED]?" and I responded with a test case that does.

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      Right! i wasn't sure who had a say. I've updated the image now :P

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      Just out of curiosity, What test case of which problem it was?

      • »
        »
        »
        »
        2 years ago, # ^ |
          Vote: I like it +5 Vote: I do not like it

        It was a test case for long long overflow if modulo is only taken at the very end in div1C.

»
2 years ago, # |
  Vote: I like it +102 Vote: I do not like it
lighthearted meme
»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

Eagerly Waiting

»
2 years ago, # |
  Vote: I like it +14 Vote: I do not like it
»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

Hello everyone. Good luck to everyone on the contest and a good rating!

»
2 years ago, # |
  Vote: I like it -17 Vote: I do not like it

Finally, I would like to dedicate my participation in this contest to myself, for doing all this hard work, for trying to get to Expert. I'm just so grateful to myself for being me at all times.

<3

»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

♥ ♥ ♥

»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

osthir vai <3

»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

Positivity Everywhere!!!

»
2 years ago, # |
  Vote: I like it +102 Vote: I do not like it

This is the first time cheaters will actually do something good to this community lol

»
2 years ago, # |
  Vote: I like it +134 Vote: I do not like it

but what happens if someone leaks div2F and 1000 people copy it

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +74 Vote: I do not like it

    the good deeds

    meme
  • »
    »
    2 years ago, # ^ |
      Vote: I like it +18 Vote: I do not like it

    Their excuse would be "I just want to help and give back to the community, so we did this for a good cause so please forgive us Mr. Mike"

»
2 years ago, # |
  Vote: I like it +3 Vote: I do not like it

Masha Allah

»
2 years ago, # |
Rev. 3   Vote: I like it +1 Vote: I do not like it

Last contest by YouKn0wWho, I gained 125 points. To date, it was my best contest ever.

Update: Candidate Master this time

»
2 years ago, # |
  Vote: I like it +287 Vote: I do not like it

Should we be concerned that the author has a monetary incentive to make weak pretests?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it -66 Vote: I do not like it

    Nah I think we should be more concerned that your rule might be coming to an end.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +36 Vote: I do not like it

    I guess if he had any monetary incentives, he would prefer not to introduce a donation system at all

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +4 Vote: I do not like it

      That's not fair. The donation system is the political move that dethroned 1-gon!

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +3 Vote: I do not like it

    Should we be concerned my words have come true?

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +38 Vote: I do not like it

      Yes, we should be celebrating the new ruler.

      • »
        »
        »
        »
        2 years ago, # ^ |
          Vote: I like it +3 Vote: I do not like it

        I honestly can't tell if you are being humble or trying to get upvotes. Let's stick with the former.

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Thanks for the generosity and look forward to this round!

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Hope I can donate more than 0.02 in this round :D

»
2 years ago, # |
Rev. 2   Vote: I like it +4 Vote: I do not like it

I hope this will be super exciting contest like here

»
2 years ago, # |
  Vote: I like it +9 Vote: I do not like it
YouKn0wIt
»
2 years ago, # |
Rev. 4   Vote: I like it +4 Vote: I do not like it

Deleted

  • »
    »
    2 years ago, # ^ |
    Rev. 2   Vote: I like it +17 Vote: I do not like it

    False, IIT BHU had previous div1 rounds

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      Ashishgup is not the authors of the round you mentioned

      • »
        »
        »
        »
        2 years ago, # ^ |
          Vote: I like it +2 Vote: I do not like it

        yup sadly he dont but in the upcoming days he will have :) , anyways still false manthan by IIT Bhu was div1 rated in past.

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Okay, after reading the full passage, i am getting more positive vibes about the contest.

Looking forward for a great contest and a motivation to keep me going.

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Poor-force will help me come to master this time

»
2 years ago, # |
  Vote: I like it -27 Vote: I do not like it

Monogon are you scared of YouKn0wWho??

»
2 years ago, # |
Rev. 2   Vote: I like it +2 Vote: I do not like it

অপেক্ষায় আছি, ভাই।

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Second time participated in your round! Love it.

»
2 years ago, # |
  Vote: I like it +7 Vote: I do not like it

YouKn0wWho is one of the best setters I know in Bangladesh.

»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

Again 1k+ upvote Sohag brother ........ <3 Keep ahead

Hopefully #752 will be interesting

»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

Good luck too all :)

»
2 years ago, # |
Rev. 2   Vote: I like it -16 Vote: I do not like it
ignore if you don't like memes
  • »
    »
    2 years ago, # ^ |
      Vote: I like it +3 Vote: I do not like it

    You mean upvote more? coz u shdn't participate with multiple accounts.

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +3 Vote: I do not like it

      Good point

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +4 Vote: I do not like it

      no, I meant Solve one problem multiple times and help the poor. just kidding... I know the rules...

»
2 years ago, # |
  Vote: I like it -135 Vote: I do not like it

...you can help the world by just solving problems.

That's quite an unique idea! At least for me this is my first time to participate in such contest.

Hope for a great contest!

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +12 Vote: I do not like it

    Why downvotes to his comment?

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +2 Vote: I do not like it

      I also don't see anything wrong in the comment.

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +72 Vote: I do not like it

      Maybe because EasonCF's comments are everywhere and people got fed up with them

      • »
        »
        »
        »
        2 years ago, # ^ |
          Vote: I like it +93 Vote: I do not like it

        Exactly

        • »
          »
          »
          »
          »
          2 years ago, # ^ |
            Vote: I like it +91 Vote: I do not like it

          But I don't think this can be the reason to downvote a comment.

          I think whether to downvote a comment depends to itself but not depends to the author.

          • »
            »
            »
            »
            »
            »
            2 years ago, # ^ |
              Vote: I like it +41 Vote: I do not like it

            It seems like saying stereotyped words to get contribution but not expressing his/her own words.

      • »
        »
        »
        »
        2 years ago, # ^ |
          Vote: I like it +63 Vote: I do not like it

        Appropriate.

»
2 years ago, # |
  Vote: I like it +47 Vote: I do not like it

Where will you be donating the money to?

»
2 years ago, # |
  Vote: I like it +9 Vote: I do not like it

Solve problems and help the poor! <3

»
2 years ago, # |
Rev. 3   Vote: I like it +41 Vote: I do not like it

As a tester, I recommend the contest to you all. As a contestant upvote the blog, or else ...

»
2 years ago, # |
  Vote: I like it +3 Vote: I do not like it

The statements are short and directly ask you what to do. Thanks for assure it and not to make the statement gazakhori and azaira pechal. :D

»
2 years ago, # |
  Vote: I like it +9 Vote: I do not like it

Thank you YouKn0wWho for keeping the problem direct and short. And your previous blog is helping a lot. ^_^

»
2 years ago, # |
  Vote: I like it +24 Vote: I do not like it

Apart from the contest it will be more exciting to see YouKn0wWho as the number one contributor ;D

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

number theory — "I am back too" xD btw great initiative ❤️

»
2 years ago, # |
Rev. 2   Vote: I like it +27 Vote: I do not like it
Meme
»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

"Donation Per AC". Go ahead with great work vai.

»
2 years ago, # |
  Vote: I like it +22 Vote: I do not like it
Meme: It's close
»
2 years ago, # |
  Vote: I like it +129 Vote: I do not like it

Upd:

Div2B: 0.005 -> 0.006

Div2C: 0.005 -> 0.008

Div1F: 4 -> 2

I hope now the distribution is more consistent with the point values of the problems.

»
2 years ago, # |
  Vote: I like it +5 Vote: I do not like it

I want to become Grand Master!

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Great initiative, you are doing a very good job. Thank you!

»
2 years ago, # |
  Vote: I like it +25 Vote: I do not like it

According to the rating predictor for last contest (education 116), my rating will go up to 1905. That means this will be my first time to participate div 1. So excited.

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

it's really good stuff that you are doing with this job, respect!

»
2 years ago, # |
  Vote: I like it +2 Vote: I do not like it

My solution for B here, https://codeforces.com/contest/1606/submission/133495767, fails in test 6. It appears to be some rounding errors. Does anyone know what caused it?

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

I want to take part in this contest but tonight, Liverpool — my favourite football cbub have a match wwith Brighton :(((

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +1 Vote: I do not like it

    I gave contest on the day pakistan beat india for first time in cricket world cups in 29 years . so deal with it .

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      let me think, I think I can watch the first 30 mins and after that, I join in the contest =)))

»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

অনেকদিন পর আজকে পার্টিসিপেট করবো ভাই :) ভাবতেই ভাল্লাগছে...

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Looking forward to my first Div 1 round!!

»
2 years ago, # |
  Vote: I like it +4 Vote: I do not like it

Alhamdulillah.. Great achievement! YouKn0wWho is now top contributor from Bangladesh. Proud of you man!

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

It is good round!!!

»
2 years ago, # |
  Vote: I like it +2 Vote: I do not like it

Excited for this one as it`s gonna be my first contest on this platform!! Looking forward to gaining some nyc ratings .....

»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

As a Bangladeshi Participants, proud of you bro

»
2 years ago, # |
  Vote: I like it +175 Vote: I do not like it

Congrats on becoming the new top contributor! Remember, great power comes with great responsibility.

»
2 years ago, # |
Rev. 2   Vote: I like it +69 Vote: I do not like it

If I'll solve E/F and resubmit it 9 more times, will you donate 20 USD?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +91 Vote: I do not like it

    But they have to pass the main tests and sadly CF skips multiple AC submissions for each problem :((

»
2 years ago, # |
  Vote: I like it +79 Vote: I do not like it

This alone made the contest worthwhile YouKn0wWho

»
2 years ago, # |
Rev. 2   Vote: I like it +18 Vote: I do not like it

I locked one of my codes for hacking but I cannot view the locked solutions of other users in my room. Kindly fix it YouKn0wWho

»
2 years ago, # |
  Vote: I like it +4 Vote: I do not like it

Very interesting problems! Thanks to creaters of this contest!

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +9 Vote: I do not like it

    but very strange problem C and I dont know how my solution pass pretests

»
2 years ago, # |
Rev. 2   Vote: I like it -6 Vote: I do not like it

Great problemset, but div2-D was quite easy compared to 2000 rated problems i think.

»
2 years ago, # |
  Vote: I like it -24 Vote: I do not like it

D was too easy tbh. C made me realize how dumb I am once again. Nice contest tho

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +43 Vote: I do not like it

    Was it? I spent over an hour staring at it and couldn't come up with solution xD

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +2 Vote: I do not like it

      I think he is talking about div.2 C and D:)

      • »
        »
        »
        »
        2 years ago, # ^ |
        Rev. 2   Vote: I like it +37 Vote: I do not like it

        I am pretty sure natofp is talking about Div1B (Div2D) based on his submission time lol.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +16 Vote: I do not like it

    Took me an hour to do it :|

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +3 Vote: I do not like it

    What approach did you used for D?

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      Did bruteforce and found the pattern.

      if(x==y)cout<<x<<"\n";
      else if(x>=y)cout<<x+y<<"\n";
      else cout<< y-(y%x)/2<<"\n";
      
      • »
        »
        »
        »
        2 years ago, # ^ |
        Rev. 2   Vote: I like it +3 Vote: I do not like it

        To add to this, a little bit more explanation on how I personally came up with $$$y-(y\mod x)/2$$$:

        Suppose $$$x\leq y$$$. We want to find a $$$n$$$ such that there exists integers $$$k,l,b$$$ that satisfy $$$n=kx+b$$$ and $$$y=ln+b$$$ (and $$$b<x,b<n$$$).
        We can see that any valid $$$n$$$ has to satisfy $$$x\leq n\leq y$$$ (*), so $$$k,l\geq 1$$$.
        Expanding $$$y=ln+b$$$, we get $$$y=(lk)x+(l+1)b$$$. This means $$$(l+1)b=y\mod x+ax$$$ for some integer $$$a$$$.

        To construct a valid solution from here, note that since $$$x,y$$$ are both even, we can set $$$a=0$$$ and $$$l=1$$$ (since RHS is also even). This gives in a valid $$$b$$$ and $$$n$$$, which is exactly $$$n=y-(y\mod x)/2$$$.

        (*) To elaborate on why $$$x\leq n\leq y$$$: If $$$n<x$$$, $$$n\mod x=n$$$ but $$$y\mod n$$$ can't be $$$n$$$. If $$$n>y$$$, $$$y\mod n=y\geq x$$$ so it can't be $$$n\mod x$$$.

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      I found the pattern after bruteforcing testcases, dont know why it works.

      basically if x>=y, ans is x+y, else y-(y%x)/2

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    Maybe I just happened to figure out the pattern

»
2 years ago, # |
Rev. 3   Vote: I like it +15 Vote: I do not like it

Thanks for great contest! I was late for an hour because of my classes but still participated in order to help charity!

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +3 Vote: I do not like it

    WOWW.. You might not know it, But man you are a hero.

»
2 years ago, # |
  Vote: I like it +43 Vote: I do not like it

Countforces Round #752

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Problem 1604C - Di-visible Confusion is logical problem ...... I didn't solve this.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it -22 Vote: I do not like it

    Did bruteforce and found the pattern.

    if(x==y)cout<<x<<"\n";
    else if(x>=y)cout<<x+y<<"\n";
    else cout<< y-(y%x)/2<<"\n";
    
»
2 years ago, # |
Rev. 2   Vote: I like it +8 Vote: I do not like it

How to get rid of TLE in pretest 5 in div1C?
I needed to get the possible next numbers can appear after index i and their count also. To do that, I needed to maintain a set.
133677385

»
2 years ago, # |
  Vote: I like it +10 Vote: I do not like it

Why a lot of solves for D div2 -__- ?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    D is a one liner solution which is perfect for cheating

»
2 years ago, # |
  Vote: I like it +5 Vote: I do not like it

Why do I think $$$O(n\sqrt n\log n)$$$ can pass 1e5 in 4s?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +16 Vote: I do not like it

    It can pass. But set runs too slow that I have to replace it with array+sort :(

  • »
    »
    2 years ago, # ^ |
    Rev. 3   Vote: I like it +5 Vote: I do not like it

    Actually $$$ \log n $$$ is unnecessary

    We Only need $$$ O( n \sqrt{n}) $$$ (Assume $$$n = \max a_i$$$)

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      Lol now I feel dumb... I used a seg tree to query on $$$O(\sqrt{n})$$$ different intervals, of course I didn't realize they will all go to the same state in the next step so there are at most $$$O(\sqrt{n})$$$ different states at any step lmao.

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Good Contest , I misread D to be find number of n from 1 to 2e18 which satisfy that condition , in the last 20 mins after looking at number of submissions I read it again , felt horrible and then mind stopped working . Anyways good contest man .

»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

How to solve C?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it -15 Vote: I do not like it

    Let me know if you find out about approach for C. Managed to solve div2 D but couldn't solve C :(

    • »
      »
      »
      2 years ago, # ^ |
      Rev. 2   Vote: I like it 0 Vote: I do not like it

      you can iterate over array and count number of items that mod(i+1)!=0
      moreover at each step you should include items that mod(i+1-1..current_count)!=0
      if at some step you found items that mod(i+1-1..current_count)==0 then answer is NO otherwise YES

  • »
    »
    2 years ago, # ^ |
    Rev. 2   Vote: I like it 0 Vote: I do not like it

    the problem is saying check if at least one number from 2 to i+1 isnt a divisor of a[i]. Its enough to check from 2 to min(i+1, 40) cuz lcm of 1...40(or so) is too big for a[i] to fit

    This is so because for the current number, if any number before it cannot be removed, ans is No. Else, you can remove some numbers and check if current number is divisible by i+1-count of previous numbers removed which results in the range 2 to i+1(notice removing numbers after current one does not affect the position so its pointless for current number)

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

The problems were very interesting. I felt dumb after getting the idea of every solution I could xD

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Can someone tell me what I did wrong in C: If there exists no element a[i] which is a product of all the numbers (i+1)*(i)*(i-1)...2, then we should output YES. Is this correct?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    I think it should be least common multiple, i.e, it shouldn't be 2 * 3 * 4 == 24. It should be the LCM of 2, 3, 4 which is 12.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    you should check lcm not product.

»
2 years ago, # |
  Vote: I like it +76 Vote: I do not like it

$$$q$$$-binomial? Are you serious?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it -28 Vote: I do not like it

    Sadly we didn't know about this. But it's true that we were afraid that some chinse guy would use some weird stuff to solve the problem. I hope you liked the other problems.

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

I got the idea of Div2D 10 minutes after the contest. I hate my life

»
2 years ago, # |
  Vote: I like it -11 Vote: I do not like it

How to solve div2 C? Managed to solve div2 D but blundered in C :|

»
2 years ago, # |
  Vote: I like it +16 Vote: I do not like it

Nice contest. But lots of maths (:

»
2 years ago, # |
Rev. 3   Vote: I like it +18 Vote: I do not like it

Didn't really like Div2 D. It's a very simple solution, and either you find it very quickly or you sit around thinking for a long time before you realize it and bang your head

  • »
    »
    2 years ago, # ^ |
      Vote: I like it -19 Vote: I do not like it

    Yea, too me a whole lot of time. At the end it was a simple pattern lol. Did bruteforce and found the pattern.

    if(x==y)cout<<x<<"\n";
    else if(x>=y)cout<<x+y<<"\n";
    else cout<< y-(y%x)/2<<"\n";
    
»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

How to solve D ?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it -10 Vote: I do not like it

    Did bruteforce and found the pattern.

    if(x==y)cout<<x<<"\n";
    else if(x>=y)cout<<x+y<<"\n";
    else cout<< y-(y%x)/2<<"\n";
    
  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    i think:

    if(x==y) ans=x if(x>y) ans=x+y if(x<y) ans=y-(y%x)/2

    although i couldn't submit in time..

  • »
    »
    2 years ago, # ^ |
    Rev. 2   Vote: I like it 0 Vote: I do not like it

    if y < x then u can choose any n larger the y so that n % x = y holds

    otherwise if y >= x and suppose y % x = z, then if you find the highest multiple of x which is smaller then y and add z/2 to it, n will become evenly match for both numbers meaning n % x will equal to y % n.

»
2 years ago, # |
  Vote: I like it +15 Vote: I do not like it

I think this time orzdevinwang will become LGM finally!

And is he the youngest LGM in codeforces?

»
2 years ago, # |
  Vote: I like it +10 Vote: I do not like it

Can someone give some hints to div1 E . I only have a naive $$$O(n^6)$$$ solution .

  • »
    »
    2 years ago, # ^ |
      Vote: I like it +14 Vote: I do not like it

    I have the O(n**6) solution but only traversing states which are reachable from the beginning and from which the end is reachable, and apparently it's fast enough. Although I guess it depends on which exact states your solution has.

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +10 Vote: I do not like it

      My solution:

      First assume that the sequence is nondecreasing . Then enumerate the first number and do a dp , which record the prefix sum and the last number .

      • »
        »
        »
        »
        2 years ago, # ^ |
        Rev. 2   Vote: I like it +13 Vote: I do not like it

        In my case the difference is that after fixing the first number I put numbers from big to small, and therefore my state is what is the maximum allowed number, how many numbers we still need to put, and what is their maximum allowed sum.

        So I guess having "maximum allowed sum" when going from big to small has fewer reachable states that having "sum" when going from small to big.

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      My states are choosing $$$i$$$ numbers between $$$[l,r]$$$ and the smallest number is $$$l$$$, the sum of the numbers is $$$s$$$.

      How could I improve?

»
2 years ago, # |
Rev. 3   Vote: I like it +56 Vote: I do not like it

Why is the time limit in D so tight??

I have a solution that runs in around 3.4s locally, and is $$$\mathcal{O}(n \log^3 n)$$$ except for a $$$\mathcal{O}(n \sqrt n)$$$ part that takes just 0.5s. I'm sure I could make this pass if I optimised my segment tree more, but the problem shouldn't require that!

EDIT: optimised the segment tree to this special case, and now it passes (133687383). Here's a submission with my usual segment tree code (133688464).

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Is it possible to do problem C in n^2.

»
2 years ago, # |
  Vote: I like it -8 Vote: I do not like it

Dear YouKn0wWho Your contets are very difficult for me T_T

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    That's what contests are for, practising and competing and having some fun. Solve some difficult problems rather than solving 200 problems of 800 difficulty.

»
2 years ago, # |
  Vote: I like it +10 Vote: I do not like it

What approaches were supposed to fit into TL and ML in Div1C by the author, and which were not supposed?

»
2 years ago, # |
  Vote: I like it +47 Vote: I do not like it
Yes Math is totally 100% Competitive Programming
  • »
    »
    2 years ago, # ^ |
      Vote: I like it +2 Vote: I do not like it

    lol. The final pattern was a simple 3 line code.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    Lol, I think my Div 2D code amassed to a couple of lines (really only 3 "important" lines of code). Out of curiosity, did the code work?

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

long long n=55; int m=20; if(m>n){ //code } Is it valid to use comparison operator between long long and int data type?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    it will first convert int to long long before comparison, so, yes

»
2 years ago, # |
  Vote: I like it +106 Vote: I do not like it

Here is some feedback on the problems:

  • A. Di-visible Confusion: Easy problem, ok.
  • B. Moderate Modular Mode: In general I don't like problems where there is 0 computer science involved, though I must admit that the statement of this one is nice. Moreover, the solution is very clean. Cool problem.
  • C. Extreme Extension: The statement is clean and interesting, but the "greedy" part is easy and the "only few states n/k" is standard. Nice statement, standard solution.
  • D. Artistic Partition: Here I have mixed feelings. The statement is absolutely "who cares". The fact that one may assume $$$k\le 20$$$ is cute. Computing the number of coprime pairs is very standard but always annoying for me. My solution is a DP with all the $$$n\cdot k$$$ states, which is optimized via the divide and conquer technique (likely different from the official solution). It was nontrivial to implement and I enjoyed thinking about how to optimize stuff so that it could get AC. Finally, submitting one minute before the end, I felt the adrenaline rush, which is priceless.

Overall, the contest was very well-prepared and it gave me some strong emotions, so thanks to the authors. The difficulty distribution was perfect. I am eager to read the editorial to find out how to solve D properly.

  • »
    »
    2 years ago, # ^ |
    Rev. 3   Vote: I like it 0 Vote: I do not like it

    Can you elaborate on the time complexity of your D? Editorial also mentions D&C and states that its actually $$$O(n \log^2 n)$$$, which I'm a bit concerned about (more like $$$O(n \log n \sqrt n)$$$).

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it +15 Vote: I do not like it

      The cost of an interval $$$[l, r]$$$ is given by ($$$q(x)$$$ is a function we have precomputed, namely the number of coprime pairs $$$1 \le a \le b\le x$$$)

      $$$ c(l, r) := q\big(\frac rr\big) + q\big(\frac r{r-1}\big) + \cdots + q\big(\frac rl\big) .$$$

      I think that your doubt on the complexity comes from the fact that computing $$$c(l, r)$$$ may require $$$O(\sqrt{n})$$$ operations (if this is not the issue, please clarify why you think that the complexity might be $$$O(n\log n\sqrt n)$$$.

      The trick is that, with some precomputation, we can compute $$$c(l, r)$$$ in $$$O(1)$$$. We precompute, for every $$$r$$$, the values $$$c(r/k, r)$$$; this can be done in $$$O(n\sqrt n)$$$. Then, we have

      $$$ c(l, r) = (m-l)q\big(\frac rl\big) + c(m, r) , $$$

      where $$$m$$$ is the smallest number such that $$$\lfloor \frac{r}{m}\rfloor > \lfloor \frac rl \rfloor$$$ (it can be found in $$$O(1)$$$).

      Since the cost function can be computed in $$$O(1)$$$, and we are executing the D&C dp optimization $$$\log(n)$$$ times, the total complexity is $$$O(n\log^2(n))$$$ (plus $$$O(n\sqrt n)$$$ precomputation).

      • »
        »
        »
        »
        2 years ago, # ^ |
          Vote: I like it 0 Vote: I do not like it

        Sorry for confusion, I didn't read the editorial, which apparently has the same solution as yours.

        You understood me correctly, the end of editorial mentions solution that uses $$$O(\sqrt n)$$$ per one query. It's now edited, stating that in practice it fits in TL but no proofs provided on the complexity (I think it's still $$$O(n \sqrt n \log n)$$$).

        Btw, I've used this technique like 2 times in recent days, but wasn't able to apply it here, what a shame...

»
2 years ago, # |
  Vote: I like it -10 Vote: I do not like it

in the problem Div2D, why x < y : cout<< y-(y%x)/2<<"\n" ?

  • »
    »
    2 years ago, # ^ |
      Vote: I like it -25 Vote: I do not like it

    If you bruteforce for the values of x and y, it was following a pattern.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it -18 Vote: I do not like it

    Can someone prove it with math?

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      For x < y, lets take K for which, K*x < y < (K+1)*x.

      The N for this case will be , (K*x + y)/2.

      N = K*x + (y — K*x)/2

      N % x => (y — K*x)/2

      y % N will be y — N (Since 2*N > y)

      y % N => (y — K*x)/2

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    if x < y, then suppose y % x = z, then if we find the highest multiple of x which is smaller then y and add z/2 to it.. then n % x = z/2 and y % n = z/2, cz they both are even numbers and I can find a midpoint where both numbers multiples distance is same.

»
2 years ago, # |
  Vote: I like it -7 Vote: I do not like it

Nothing is better than doing charity while having an interesting competition!

»
2 years ago, # |
  Vote: I like it +89 Vote: I do not like it

Unpopular opinion: Div2 was only observation and math, no programming. Boring experience.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it -11 Vote: I do not like it

    Sure, but isn't 'observation' key to 'problem solving' which is pretty much what competitive programming is. A keen observer is usually also a shrewd problem solver.

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it -15 Vote: I do not like it

      No, but I expected more data structures, algorithm concepts such as binary search.

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      Implicitly, in your argument, you assume that observation means math (or that, observational problems are inherently mathematical problems). I don't think that's true. Sometimes just observations can come from realizing that one needs a certain data structure, like recognizing the application of segment within a particular context.

      I agree that observation is key to problem-solving, but I don't think this justifies having such a mathematically heavy contest.

»
2 years ago, # |
Rev. 2   Vote: I like it -12 Vote: I do not like it

Does the writer have fetish with XOR? Why so many XOR problems from the same writers?

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Can someone explain why this code gets WA? I literally did the same thing as explained in the editorial Link: Your text to link here...

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    You don't read the complete input before printing the output for a test case. Then when you'd try to read the next test, you'd first receive the input left from the previous one.

    • »
      »
      »
      2 years ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      Yeah I realized that in the meantime. Stupid of me, what can I say. Thanks for explaining anyway!

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    You don't need to check for all the n elements, just for the first 21 elements.

»
2 years ago, # |
Rev. 2   Vote: I like it -33 Vote: I do not like it

.

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    I just went ahead and downvoted you for saying that. Thank you

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Just solved Div2 D just 8 sec before the Contest Ends, Love my Life and codeforces

»
2 years ago, # |
  Vote: I like it +6 Vote: I do not like it

It was a math contest, didn't even need computer.

»
2 years ago, # |
  Vote: I like it +19 Vote: I do not like it

There were so many $$$69$$$'s. YouKn0wWho surely loves $$$69$$$.

»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

I want to know the name of the man who ranked 2 during the contest and suddently dissappear after system test .-.

»
2 years ago, # |
  Vote: I like it +3 Vote: I do not like it

anyone calculated the final donation amount?

»
2 years ago, # |
Rev. 2   Vote: I like it +38 Vote: I do not like it

My personal feeling — E is much, much easier than D. For me E is a pretty standard task like "you have an obvious DP with huge complexity, optimize it with some observations and harmonic series principle". D's idea is obvious to me too, but implementation and some specific details make it harder for me.

»
2 years ago, # |
  Vote: I like it +202 Vote: I do not like it

Despite my feelings of losing rating and my contribution throne, the problems div1ABC are pretty nice. If I have a suggestion for improvement, it's to have more topic balance. I thought there is too much number theory. (As much as integer division and remainder can be called number theory)

»
2 years ago, # |
  Vote: I like it +13 Vote: I do not like it

Great contest I enjoyed solving the questions and also happy for donating.

»
2 years ago, # |
Rev. 2   Vote: I like it +3 Vote: I do not like it

Silly thing happened to me today, I forgot to save file after removing cerr line and submitted the unsaved file. It passed pretests but TLEd on actual tests. Is there any way to use fast output with cerr?

meme

P.S. use clog instead of cerr

»
2 years ago, # |
  Vote: I like it +8 Vote: I do not like it

The contest was good, though i think it was a bit mathematically. thanks the writers

»
2 years ago, # |
  Vote: I like it +46 Vote: I do not like it

Does anyone know why Itst_boyfriend was removed from the contest?

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

When will ratings update?

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Can any one make me clear how the O(N²) solution is getting ac in div 2 question C???

  • »
    »
    2 years ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    Brute force works here because it is not really O(n^2), because actually most numbers can be removed in most positions. So a linear search for such a position does not take n steps but at most aprox 20, and on average about two or three. submission

»
2 years ago, # |
  Vote: I like it +2 Vote: I do not like it

This guy never disappoints. ❤

»
2 years ago, # |
Rev. 2   Vote: I like it -24 Vote: I do not like it

I mistake

»
2 years ago, # |
  Vote: I like it +35 Vote: I do not like it

you know it's a bad contest when problem D has O(1) solution

»
2 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Dear programmers, can you help me? Recently, for fun, I created a team of friends at Codeforces. After the contest, Codeforces sent me an email saying that my solutions are very similar to the solutions of alex_2008, which is in our team. The fact is that I am also alex_2008. And there in the letter it was said that for repeated violations of the rules, they would block my account. Can you tell me what to do?

»
2 years ago, # |
Rev. 2   Vote: I like it +10 Vote: I do not like it

I participated in the round yesterday. I received a mail after the contest that my solution for DiV2 Problem B coincided significantly with two more solutions(My solution -world_classic/133631831 133631831 others solution-keetzo/133671951 133671951 , kaypee284/133672077 133672077) . As the question had a straightforward solution and the other users coincidently may have the same templates as mine so it may have coincided by chance. I request MikeMirzayanov and the team to look into the matter...

»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

I am amazed at how accurate your estimation is!!

»
2 years ago, # |
  Vote: I like it -8 Vote: I do not like it

As a tester, hope you got nice rating

»
2 years ago, # |
  Vote: I like it +106 Vote: I do not like it

So I promised that I would donate a certain amount of money based on the number of ACs that each problem gets. The idea was to motivate people to solve problems and at the same time help out real people by just having green verdicts.

The amount turned out to be around 200 USD (I have received 400 USD in total for that contest).

So following that event, today I have distributed Iftar platters (Ramadan Meal) of the same amount among 120 rickshaw pullers and poor people in general. Thanks to Toushiful Ferdous Badhan and Rakib Hasan for helping me out.

Posting here to let you guys know that, hey, your green verdicts helped someone to have a green moment. Also, you solved a div2A problem but that way you just helped someone solve a real div1F problem which is Food (may it be for one day).

We can’t change the world overnight but we can play our parts, may it be very little! I like the analogy of one of my friends which she calls "The Wave Analogy". The particles stay where they are, they just dance and in consequence, a big wave is formed!

food-donation