Top Recent Blog Posts
By creep, history, 29 hours ago, In English

actually i haven't even visited topcoder website

but i condemn canceling (bela)russians and banning accounts, which is happening according to many residents of these two countries

i'm wondering why hasn't anyone posted about it yet? i can understand if nobody cares about losing their profile, but the problem itself is pretty interesting

Read more »

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

By kpw29, 30 hours ago, In English

Introduction

So, I set myself that challenge to retire as a red coder before 24.09.2020... and I failed miserably. At least I am less delayed than most civil infrastructure projects.

This blog will be a recap of this short challenge with a mixture of some tips on practicing (for all levels!), some random life advice and, of course my bad sense of humour. It is dedicated to all those who aren't wonderkids, go from failure to failure and feel like banging their head into a wall during most of their competitive programming journey. Whatever your goal is, I'd like to strengthen your beliefs — you can do it!

How it all started

My skill level has been in constant stagnation for years. I've always thought that I'm just not talented enough to be a grandmaster. Although I've been red twice in the past, it was quite lucky and the next contests were solid $$$-137$$$ and $$$-189$$$ so that life could get back to normal. If you know a bit about chess titles, you are probably aware that you need to score three so-called norms to be granted a title for your lifetime. Thus, I wanted my third one.

In 2019 I noticed that an acquaintance of mine, kostka did something very impressive. His rating just exploded. I was inspired by Bartosz's improvement. Maybe I wasn't doomed to be yellow forever?

By the way, there's also a thread about users with inspirational rating graphs

What didn't work — the beginning

At the beginning of the challenge (spring 2020) I didn't really change much in my CP. I was kinda doing the same thing over and over, orbiting around 2300, hoping that a good performance is bestowed upon me and I can finally get red. Oh, how foolish it was... Just participating in contests did not, obviously, increase my skill.

Around June 2021 I was already almost late one year with completing the challenge. My exams were over, the delayed ICPC finals (September 2021) were coming. I decided to take my practice seriously. I wanted to be a better competitor and team member. For that, I needed to seriously improve. I started doing virtual CF contests and upsolving almost every day. That was quite a challenge, because I had already started a full-time job. I would wake up before 7 AM, do some CF contest, and then go to work. I, the lazy night owl, had to become a morning coder, it was painful at start, but doable. That was the only way if I wanted to keep up with my training partner, tnowak (ahh, those lucky university students). I did around 45 contests during the summer, upsolving usually at least one problem per contest. Yet, my CF rating wouldn't move. Actually, despite feeling much more confident in implementation, I lost around 200 rating points after the summer. I was quite purple then, and I needed to climb 450 rating points to regain GM title. Yikes.

The truth is that although older CF contests were very good practice for ICPC, they are not a very good source if you want to gain rating in 2022 (at the end of my trainings I was doing some contests from the 200-300 range...). Modern problems are different, rarely focusing on implementing some standard algorithms, much more mathematical instead. A nice library won't help anymore.

What worked for me

Six months ago demoralizer wrote a blog (it is deleted/hidden now, I can't find it anymore) offering coaching for yellow competitors hoping to get better. I reached out, and he, being a really nice guy, shared with me his recipe: First solved 100 2000 rated problems then 100 2100 then 100 2200 and so on...I reached red before I could solve a 100 2300 problems...

Fair enough, such a grind seemed doable. But I added a little twist to it — I practiced on AtCoder since I was notoriously bad at problems involving combinatorics or other mathsy stuff. And I needed to improve my thinking skills, too. With the help of kenkoooo website (great website, check it out!), I could easily find problems at the right level. In the next three months, I solved 100 yellowish (2000-2400 rating) problems. After that, tnowak became curious about effectiveness of this training and suggested I do a couple of virtual contests to compare my performances. The results were astonishing. The average of five contests I did was around 2500, two hundred rating points above the summer average. After two years of struggle, I finally became better.

Seeing the tangible results, I continued my trainings this way, skipping to orange (2400-2800) problems this time. I got red on the 23rd April, by the time I managed to solve 50 of them. Roughly two years after I started the _simple_challenge of gaining 100 rating points.

A universal practice method

If you're stuck or wondering how to improve, here's a simple recipe how to get better. The advice to "solve more problems" always irritated me. You may be unsure which problems to solve, how long to solve them, or just want to have a practice method that worked for someone else, here is what you need to do.

  1. Find a range of Atcoder problems which you can solve in around 60-90 minutes.
  2. Solve them, one by one, in some order which sounds reasonable to you. You can open many problems and think about them in parallel. You don't need to get them accepted in order, but try to get all the problems you see accepted eventually. Try not to look at editorials, but don't be too afraid to look at the editorial if you spent significantly longer than expected. You failed to solve that one, it happens.
  3. Repeat. You'll improve quickly if you just follow this routine. Probably quicker than I did.

Here's some rationale why it should work. This problems range are the critical problems for you, they are in something that Um_nik in the best and truthest blog on Codeforces ever calls an interesting interval. If you haven't read his blog, go and do it now. Seriously, it's the best advice. Worked even for me. Thanks, Alex! (though to be precise, I have already been applying the takeaways from the blog before he published them. But I wanted to mention his name since he described it first and very well — I'm just highlighting that this indeed DOES work).

To improve, you want to be tackling the problems that you would be reasonably hoping to solve during the contest, and be faster in getting them accepted. That has three factors: coming up with the solution idea, clarifying the solution and making sure that it works, and only then implementing it. The third step should usually be straightforward -- if you have troubles implementing your solution, it means you haven't thought through it well enough. The faster you are at getting these challenging (for you) problems accepted, the more likely you are to solve more problems during the contest (as you have more time), and by facing obstacles on the right level you also don't waste too much time. Some may argue that usually solve within the contest level is too easy, or that reading editorials is bad. I didn't have infinite time to think about problems, and I wanted to feel confident that the problems are within my reach so that I can avoid the temptation to look at the editorial. That felt very important to me. When I was in high school, my teacher would usually give the same extremely difficult problem over and over to the top students until someone finally solved it. I developed sort of a PTSD for too difficult problems, wanting to quit as soon as I saw one of them again.

If you're on your own however, nobody will be torturing you with too hard problems, but you need to find a way to efficiently select problems to solve. I would always solve problems randomly — from various online judges, competitions or from my juniors. But overall I wasted a lot of time searching for tasks or solving ones that were not developing me (that includes participating in contests that mostly consist of problems you can solve). This is where the proposed practice method excels — you don't do that at all. Because AtCoder problems are all (or almost all) of very high quality, you have a nearly infinite supply of good problems to practice on. A word of warning here — if you're preparing for ICPC or some other coding-and-algorithm-heavy competition, consider moving to something ICPC-like from time to time).

If you really like contests, you can also use the kenkoooo website to create contests out of the problems from your range. It's also a fun way to challenge yourself. An additional tip would be to try to do it page-by-page. While it may not work like that for everyone, I found it useful to set mini goals for myself, and felt very happy after filling the entire page with shiny green colour. I practiced here

Do you have to do it?

I'd like to conclude with a small remark to be wise about your goals. Writing software is all about tradeoffs. Your life is all about tradeoffs. There's always an opportunity cost, for all things you do. During your practice time you could instead be hanging out with friends, practicing your interview skills to get a real job, or getting involved in some random machine learning startup that will make you rich. Before you declare you want to be a Legendary grandmaster (while cyan at the moment), look into the mirror without blindly following the crowd and ask yourself if it's really worth it. If CP is your passion and red/orange/purple is your dream, go ahead and do it! I believe in you :)

Read more »

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

By maomao90, history, 22 hours ago, In English

Slope trick is one of my favorite algorithms, so I have been considering writing a blog about it. However, there are already a lot of resources about slope trick, so I am not sure whether anyone would benefit from yet another slope trick blog.

If I were to write a slope trick blog, it would focus more on the intuition behind how I solve slope trick problems together with multiple difficult example problems (not 713C - Sonya and Problem Wihtout a Legend) where I show my step by step thought process. If you would like to see this slope trick blog, please upvote this blog. I will write a slope trick blog if this blog receives more than 100 upvotes. Thanks for all your support 👍

EDIT: Wow, already more than 100 upvotes in such a short time. See you in my upcoming slope trick blog 😉

Read more »

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

By rivalq, 12 hours ago, In English

I hope you all liked the round. Please share your feedback in the comments section.

1682A — Palindromic Indices

Hint
Tutorial
Solution

1682B — AND Sorting

Hints
Tutorial
Solution

1682C — LIS or Reverse LIS?

Hint
Tutorial
Solution

1682D — Circular Spanning Tree

Hints
Tutorial
Solution

1682E — Unordered Swaps

The tutorial will be available later

1682F — MCMF?

The tutorial will be available later

Read more »

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

By sid., history, 3 days ago, In English
 
 
 
 
  • Vote: I like it
  • +353
  • Vote: I do not like it

By KrowSavcik, history, 5 hours ago, In English

This blog is the story of how I became CM in the last contest. I hope to motivate you with this blog.

The beginning

Usually I know how to do first 3 problems right after reading them, but today it was different. I tried A and failed. Then I tried to solve B. No result. On C I got WA on pretest 2. I fell in despair, as I realized that I will lose rating. I understood that it was no use to stress myself anymore. I turned off my laptop and went to my friend. I brought my laptop with me, but I had no intent to continue the contest.

At my friend's house

After a 5 minute walk I got there. After some talking I opened my laptop and looked at the problems again. It was different this time. Every problem was clear. I had the time to solve ABCD and was satisfied after the contest. In the end I even got rating and became CM.

I learned a lot from this experience and I want to share it with you.

Don't pull yourself

You shouldn't pull yourself. Life is full with problems and worries. At least now, while doing competitive programming, you should be relaxing.

Take breaks.

If you feel stressed, you shouldn't hesitate to take a break. Returning at a problem after some time, might give you new ideas and help you see things that you missed before.

We must always look at things from different angles. — Dead Poet's Society

Read more »

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

By antontrygubO_o, 4 hours ago, In English

We will hold Codeforces Round #794 (Div. 1) and Codeforces Round #794 (Div. 2).

The point values will be:

Div2: 500 — 1000 — 1500 — 2000 — 2500 — 2500

Div1: 500 — 1000 — 1500 — (1500 + 1500) — 3500

We are looking forward to your participation!

Read more »

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

By chokudai, history, 44 hours ago, In English

We will hold AtCoder Beginner Contest 252.

The point values will be 100-200-300-400-500-500-600-600. We are looking forward to your participation!

Read more »

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

By fvogel, history, 10 hours ago, In English

Hello Codeforces,

I couldn't find any blog on this year's round C so I decided to create one. Feel free to post your feedback and ideas on the contest.

Personally for me the start of the contest went pretty well. Problem D was particularly interesting and I solved it quickly. However I found problem C quite harder and got quite a few WAs. But I finally got a perfect score!

I plan on hosting a live discussion about the problems from this contest today at 6:00 PM UTC. The link will be posted here shortly. See you there!

Happy coding :)

UPD: Here is the link: https://www.youtube.com/watch?v=jvc_4ZT9da4

UPD 2: There's been a bug, here is the new link: youtube.com/watch?v=SL1-YYocQik

Read more »

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

By ilia_rr, 7 hours ago, In English
 
 
 
 
  • Vote: I like it
  • +69
  • Vote: I do not like it