Hello, Codeforces!
I am very excited to invite you to my first-ever contest, Codeforces Round 1034 (Div. 3), which will start on Jul/01/2025 17:35 (Moscow time)! In this contest, you will be given 2 hours and 15 minutes to solve 7 problems.
The round will be hosted by the rules of educational rounds (extended ICPC). Thus, all solutions will be judged on preliminary tests during the round, and after the round, there will be a 12-hour phase of open hacks. After the open hack phase, all accepted solutions will be rejudged on successful hacks. Also, note that there is no score distribution — rank will be determined by number of problems solved, followed by penalty; wrong submissions will incur the usual penalty of 10 minutes, following the rules of educational rounds.
As a reminder, only trusted participants of the third division will be included in the official standings table. This is a compulsory measure for combating unsporting behavior. To qualify as a trusted participant of the third division, you must:
- take part in (and solve at least one problem in) at least five rated rounds
- and not have had a rating of 1900 or higher at any moment in time.
Regardless of whether you are a trusted participant of the third division or not, if your rating is less than 1600, then the round will be rated for you (unless you register unrated).
Also, note the rule restricting the use of AI. If you are caught breaking this rule, you will be met with unfathomable punishments, so for your own well-being, I highly recommend adhering to the rules.
I would like to thank the following people for helping make this round possible!
- cry for being a very orz coordinator, and Vladosiya for translating the statements into Russian;
- Lilypad for being my sounding board for problem ideas;
- Dominater069, __baozii__, AksLolCoding, Proof_by_QED, Edeeva, -firefly-, efishel, Friedrich, Vladosiya, Hori, macaquedev, DivinePunishment, SpyrosAliv, beaten_by_ai, Filikec, Non-origination, kevlu8, yse, and AG-88301 for testing;
- Intellegent and chromate00 for pretending to test;
- MikeMirzayanov for the incredible Codeforces and Polygon platforms;
- and most importantly of all, You for participating!
Good luck, and have fun!
Update: Editorial









As a tester, I enjoyed the problems and encourage you to participate.
Hope to reach green again in this round and
Not to see Pupils and newbies in top 10
2 pupils and 1 newbie are in top 10 rn
As a participant, I too enjoyed the problems
yea contest was best others are very hard this one was best
Hope I can reach specialist again (bad perf too many times already — nooo)
As a tester, I recommend everyone to watch Toaru Kagaku no Railgun.
It's soooooo good! I recommend it too. Gives +500 elo boost ;)
I've heard of it but never got to it cause of Magical Index :/
As a tester, I like being at the front of the list of orange testers.
As a tester, I'm going to send every single GPT cheater into cry's basement and lock them up so they never see the light of day ever again.
As a nontester, I concur with this
As a tester, you do not want to know the unfathomable punishment that is cry's basement
.
As a real not-pretend tester, do the contest.
no div3 tester for a div3 :(
a normal div 3 round usually contains question(s) that even I can't solve.
thats true
mb!
I understand that the upper bound of difficulty is often beyond what a div3 person can solve, but even still I think having div3 testers would still be very useful to get a wide range of perspectives
As a so called pretend tester, I’ll have you know I solved a non-zero number of problems whilst testing the contest.
Negative be like
You solved it in the last minute...
Thanks for spoiling contest difficulty, now I know at least one of the problems is solvable :(
As a chkek person, I hope I don't face technical issues 5 minutes before the round and have to skip.
chkek
chkek
Hello alnq
chkek
i find ur dp distracting
Hopefully, the rating changes will be applied before 2030.
as an unofficial and un-trusted participant, i convinced my friend to do this contest
hope the problemset is awesome and enjoyable !:)
As an unrated participant, I urge all unrated participants to not attempt contests from ALT accounts. (Do not snatch from the poor, karma hits)
Wish me luck pls for reaching to Green line!
Will the theme of the contest be Toaru Kagaku no Railgun?
no, there's no theme for this contest unfortunately
maybe i'll write another contest when season 4 comes out though... we'll see :)
No need for 12 hour hacking period 1-2 is enough. Otherwise we have to wait 4-5 days for results.
I don't like so much time of hacking either
get addicted to hacking u will think 12hr is also less
long time no contest, hoping for positive delta.
I might finally reach green this time, I am going on a good pace :)
good luck bro
Thank you for the contest
Where is that meme (Expert be like : I'm out of competition) ???????????
First time i can say, I'M OUT OF COMPETITION!
I hope to try the same feeling after the round.
i hope you do!
Hope to AK the round!
Couldn't make it :(
problem G was too difficult for me
Fun (and knowledge) is main
hoping i don't bottle this time (pls i wanna reach green)
Make sure that you are around 6000 on the standings...
Hoping to make a delta of +100 jump tonight..!
tired of solving 4 questions and falling down to newbie. Hope to solve 5 questions
I think, the 5th one needs a little algorithmic touch...
Too tight TL on G imo
sum of $$$m$$$ is not limited
Oh you are right.. my bad
What's the main idea of problem G?
It was a great contest. Except for problem A, I found the other problems clear and approachable. Managed to solve upto D and gave F a try. I do regret registering as unrated.
can someone explain D ?
If initially the amount of 1 is no greater than k or the length n is less than 2*k,then Alice win.
If initially the amount of 1 is no greater than k,Alice can win in the first round.If the length n is less than 2*k,every time Bob operates,it must change some certain positions (like k) into 1,then if Alice doesn't change these positions into 0,the amount of 1 will eventually lessen to k.
Loved solving E
Thank you authors
can anyone explain problem D — I tried and tested it on my Python IDLE too but somehow it was showing wrong answer on test 2 my submission
If the number of 1s is equal or smalle than k, obviously Alice will win. Keep writing down the test cases on paper until u realize that Alice can't win when 2 * k <= n.
How could you "realize" that so fast? please teach me
I just do
Thanks bro!
Nice contest! Best description and questions comparing with the few past contests! Problems are clear and fresh to look at. I solved 5 problems and a bit regret to register unrated. (Although I'll still lose rating if it's rated lol)
Got stuck in problem B for five tries until I found that I input k and j in the wrong order OMFGGGG!!!! (At 2 hours :)) Never done such stupid thing before!!
Anyways, good contest and looking forward for the editorial!
UPD: Super quick editorial out yay :)
guessforces
Stuck at problem D QAO It took me 100 minutes
guessforces !!!
Somebody injected a TLE when the number of bits sets in $$$n$$$ in problem F is $$$11$$$. The code got copied all over the place.
please can I get rating I had a internet issue I was waiting from a week for this I practice alot but when my internet fixed it was too late only 1 min was remaining I have done 4 problems A,B,C,D after contest please give me the rating if u can give please or please give me extra time please I just wanna complete 1400 rating by my self and this was a chance for me I'll check my internet next time reirugan
thanks
-- VSS102484_farazUsman
From the submissions, it seems like we going to see lot of plags
This was one of the best div 3. Specially problem E & D are too good :)
Ya, problem E is good
E was a good problem. F was good too. Overall a balanced and good problemset!
Screencast with commentary
Problem G: I notice that there are at most 200 different factor for m <= 5e5. So for every factor I build a segmentTree.But I got Memory limit exceeded on test 13...
You have three vectors with 4n size, so that's $$$12n$$$. You are storing $$$200 * 12 * 100000 = 2.4*10^8$$$ integers. Should be too much.
Yes you are right.o( ̄▽ ̄)d
I wasn’t planning to participate, but at the last moment I thought, let’s give it! And wow it turned out to be my lucky contest!!! Ended up getting an official rank of 92 that was totally unexpected! I wasn't ready for that mannn!
I’m going to be an Expert now lol! well I might fall back to Specialist after the next contest but still I will have an Expert max rating now yeeahhh.
This honestly gave me Luffy Gear 5 level goosebumps
why its not showing my rating it was my first contest
amm rating hasnt been updated yet it will get updated soon enough dont worry
Thank you for such a mind blowing contest!! I Litrally have no words rn….
Your progress speed is really impressive! Could you share what you do to improve from a pupil to an expert (or even a higher level) in just half a year?
So this is the first time I am speaking about my progress. So I put some time into thinking what to write.
Firstly, I am an engineering student who cleared the JEE Advanced exam to get into IIT Varanasi, so I got my maths foundation from studying for the exam.
About before, I was a rage coder I guess, I used to force myself to find a solution to the problem I was looking at, instead of going with the slow of the problem and attempting those which I could solve, I used to try to solve the one in front of me.. I think that really held me off.
So I decided to up skill myself reading some books, the one which I found really interesting was a competative programming book — Competative Programming 3 by Steven and Felix Hamlin. It really helped me put my idea into words and writing, which helped me build upon the part of the solution I already had done,.. So this step by step process is actully what helped me I guess. Also Shayan's YouTube channel proved really helpful for me. Also this round was so mathematical and my simple yet good background in algebra and number theory proved useful here.
Throught the whole contest I was just focused on solving the questions I believed I could solve, tho I did solve everything at the end, but I never expected it from me.
Also, to add I believe this was a really "right time, right place" thing happening with me, some might call it a fluke... but then I remember what Kevin Malone from "The Office" would say to this:
"Look I know it's easy to say tonight was just a fluke, and maybe it was, but here's a piece of trivia — a fluke is one of the most common fish in the sea. So if you go fishing for a fluke, chances are you just might catch one."
I really like Problem E, even though I didn't manage to solve it during the contest.
loved the questions, solved 4 in first 30 mins, 5ht took time due to silly but and got logic for 6th but couldn't complete it
I solved two problem,and this is my 2nd contest,why there is no change in my rating??That's discourage me
Cause you registered as an unrated participant lol.
D was tricky!!