I did really poorly in Round 562 Div 2 managing to only solve problem A. I did manage to come up with a logically correct solution for problem B, but it was too inefficient and timed out. After the contest I had to look at solutions of others to understand how to speed up my solution for B. I never even got a chance to look at C,D,E.

How would you go about upsolving? I did already look at problem C, and I think I might be able to come up with something after a while, but what about D, and E? Is it even worth upsolving those if I'm struggling with B level problems? Also how much time should one spend trying to upsolve before looking at solutions?

Thanks!

u should upsolve atleast two problems that u were unable to solve after contest is over

Thanks, I'll give C, and D a shot.

Since it was your first contest, I'll assume you are new to CP (or CF) in particular. So I'll go easy on ya.

Upsolving won't get you far unless you learn to exercise your brain (i.e. be creative)

On a side note:

(1) Don't bother taking part in contests till you are really good (i.e. you can solve at least 3/4 the problem set). Otherwise, you are just wasting time.

(2) It is common for newcomers to overestimate their skill until they do their first contest. You are not the first, nor will you be the last. Take this failure in your stride.

(3) Learn that CP is not about who knows the most algos, done the most qns or spent the most amount of time. It is about who uses his/her brain the best. To do that, practice on math/ad-hoc/creative tasks. Those are the ones that help you exercise your brain compared to, say, some ds question like finding number of distinct elements in a range. The latter type of questions have quite standard solutions that you will learn eventually after enough practice.

Since it was your first contestWhen will be yours

Lol. Why are you so interested in my first contest?

People expect knowledgeable people to be giving out knowledge. Not saying you're not knowledgeable (could very well be a smurf).

But knowledgeable people don't necessarily have to do the work themselves right? I prefer to give advice than to do the work myself because I am lazy.

So you cheat because you're lazy? :thonk:

LOL. What do you mean by cheat? How to cheat if I don't participate in contests? XD?

Because you are one of the most famous persons on codeforces

Coaches never play

Lance is like one my friends who gives the best relationship advice but is still single.

Well, I could be a red coder for all you know :wink: :wink:

What about if I get stuck on some question where there is a specific common algorithm or data structure I don't know about?

How does one go about recognizing this so they could go and study up on that specific gap in knowledge?

Easy. If you cannot solve a problem, there is a "gap" in your skill. So you are going to have to fix that.

But I mean there's a difference between missing some idea in the problem vs not knowing a common algorithm which solves the problem is there not? Or would you say both are just a lack of experience?

It is not entirely about experience actually. It is often caused by the way one thinks (e.g. some people tend to jump straight to tackle the main problem which might be very hard but they could instead solve a more trivial instance which might lead them to the solution).

More often than not, you might face the "missing idea" problem because as I said, CP is not a game of rote-learning.

So if its not entirely experience, how does one get better at thinking in the way you described?

Do you have any specific tips?

Do more math/ad-hoc/creative tasks.

This is quite interesting. Would you say that most A,B level problems at Div 2 are most likely some kind of ad hoc problems? I haven't encountered one yet which uses some alg or ds that I simply dont know about.

I am not saying that div 2 A, B level problems will use advanced DS algos. But some beginners tend to focus on the wrong things. Thus, I mentioned in my notes not to bother about these sort of stuff too much.

Most div 2 A, B problems are just implementation. B sometimes requires some simple observation. So I reckon that wouldn't trouble the average Joe.

If you struggle with div2-B, then solve a lot of div2-A/B problems (div2A are more to make you more efficient with just-implementation things).

Thanks,

Is there some way to sort the questions specifically by Div2 B? Earlier I sorted by easiest, but I found those questions to be way too easy so im guessing those were not even Div2 level questions.

Also how do you go about identifying common data structures or algorithms that you might be missing when getting stuck on a problem?

Sort by the difficulty value and binary search proper difficulty for you.

Also im assuming that you wouldn't recommend for me to up solve C,D,E until I get comfortable with A,B right?

As someone who has participated in a few contests so far, I can tell you that you won't get the chance to solve C, nor will you have the necessary knowledge to solve C unless you can solve A and B under an hour. I can personally say that doing a lot of A/B tasks has helped me improve in my time taken to solve A/B, but I still need to do a lot more if I want to reliably do A/B in contests. From personal experience, A is either purely implementation (a.k.a. do this exact thing we tell you) or just a small observation, or a small trick that once you learn over many A's, you can solve through in under 15 minutes. Div2 B can be quite tough for me, as sometimes I'm not able to figure out the implementation of the problem, as in, since most B problems have constraints big enough that you kinda have to do in O(NlogN) time or less for it to work, you need to come up with a greedy/math solution, and that can sometimes be tough to do, but even tho I haven't actually practiced enough to solve B reliably, I am seeing progress, and seeing how there are many CF users here who have gone through the same process and now are solving ABC in under an hour, practice is the key here. C is from experience also usually an implementation, but you need to have a bit more knowledge about implementation itself, so I think when you get the hang of B, you'll quickly start solving C as well. D from experience (in Div2) is math + algorithm type of problem, that is usually easy to do IF you know the algorithm or you are good at math. The rest are the same as D but more complex.

If you read the problem, thought about it etc. solving it makes some sense.

If you didn't even read it or read it and discdarded it right away then that problem doesn't differ much from all other unread problems in the world. And then it would probably be more beneficial to spend time on solving problems better suited for your current skill. I would advise to use "difficulty filter" in problemset tab: https://codeforces.com/blog/entry/62865

Obviously rating is more adequate after few contests, since there is some variance involved, but this is some starting point at least.

Yea I suppose this is a good point. I'll focus on Div 2 A, and B for now.

Thanks.