IngaleAnkur10's blog

By IngaleAnkur10, history, 4 months ago, In English

Problem: 104555E - Extracting Pollen Submission: 277763292 Also, is there a way to access gym test cases? Thank you!

Full text and comments »

  • Vote: I like it
  • 0
  • Vote: I do not like it

By IngaleAnkur10, history, 4 years ago, In English

Please do let me know if this exists already.

Many programmers (including me) use two or more programming languages in a single contest. But searching them before submission is a bit time consuming.

One way to solve this is to have a favorites section where we add our languages beforehand. During a contest, putting the favorites mode on should only give us our selected languages. This way it will be very time-saving.

Comment your thoughts on this idea.

Full text and comments »

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

By IngaleAnkur10, 4 years ago, In English

In the past 4 contests, my rating dropped from 1826 to 1490 (336 points). I really don't understand what went wrong. There were some type of problems which I never saw before, but I was not able to solve even the known or easy ones. What should I do?

Full text and comments »

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

By IngaleAnkur10, history, 4 years ago, In English

Codeforces Global Round 10 had some really good problems which required deep thinking for Div.2 folks. And, to not able to solve some problems in the start itself is demotivating. I have seen many folks, including my friends, just quitting the round if they are stuck at some problem. Many of you would have done that too.

So, I am writing this to share my experience in this contest. Here's what happened:

  1. Problem A was easy, just a little thinking would do. Still, that easy problem took 5 mins and I was already behind the race.

  2. I solved B a little early, grabbed the pace and came in the competition. I felt this could be my contest.

  3. Spent 30 mins on solving C with 3 wrong submissions. Finally, I did solve it.

  4. Spent 70 mins on solving D with 6 wrong submissions. Finally, solved it.

Now, the question is what went wrong for 6 WAs and why I kept trying D. To answer the first question, I did not go through the cases well. I hurried my decisions, came up with a very, very wrong solution, checked sample test cases and submitted them (you can go through my submissions and laugh at me, I won't mind :-)).

Now, why I kept trying D. Two reasons: my friends weren't able to solve E, but they solved D. That gave me hope. And, I wanted to save my rating from falling a lot, so I didn't quit.

So, how did I keep my cool?

After submitting 5 WAs on D, after trying various approaches (but fundamentally still wrong), I took a small break like a minute or two. Then, I read the problem statement again as if I was reading it for the first time. I constantly tried to remove the solution I thought from my mind and think of something new. And, I found it!! I found a new way to solve this problem, and there I found my mistake in the former solution.

But, I had another WA!! I was completely demotivated for a second, only to realize I made a silly mistake. I immediately corrected it and submitted it again. And voila!! AC!!

Fact: I saved my rating from -90 to -23.

How can you keep your cool?

The simplest way is to take a minute break and approach the problem from a completely different point of view. It's okay to mess up. It's okay to have such many WAs. Just keep trying. In the end, this is a part of learning as well.

Sometimes, some things just don't strike us. For example, not remembering some rarely used algorithm. It's okay. Just give some time.

  1. Take a break.
  2. Read the problem statement as if you are reading it for the first time.
  3. Jot down all the points and conditions in the problem statement.
  4. Think again and do not let your old solution come in the way.

Try this, the next time you face something like this. Stay safe and keep coding!!

Full text and comments »

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

By IngaleAnkur10, history, 4 years ago, In English

Greetings Codeforces Community.

I suddenly came up with an app idea where a user can create custom three-man teams, and check the overall strength of the team. Please do note that the data will be fetched from Codeforces API, and therefore, the team strength will be calculated only based on the performance of the team members on Codeforces ONLY.

Although this idea seems interesting, I am really confused so as to what metrics shall be used to calculate team strength based on individual member data. I came up with some like the maximum problem rating of each member where they feel comfortable, the tags of problems which the member is good or bad at depending on the number of submissions, etc.

I request the community to add more metrics and put their own ideas. I promise to develop it :-P.

Full text and comments »

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

By IngaleAnkur10, history, 5 years ago, In English

I request you all to answer the following questions based on only your experience and nothing else.

  1. During a contest, when you get a solution to a problem, do you actually prove the solution to be true or just use some test cases and check if the solution works correctly? I feel the latter answer is obvious but I would still like to take a poll. The reason for asking this question is because sometimes, I am just not confident enough on my intuition and feel like I am missing some test case which can prove it wrong. Also, I am not that good when things come to prove something though I understand the proofs done in the editorials. Lastly, when I submit it (my intuitive solution) and I receive a WA, it demoralizes me to such an extent that I feel I should quit the contest immediately.

  2. In a greedy vs dp scenario, how do you judge if the problem can be solved greedily or not? I am new to dynamic programming (though I am practicing it for the past few months) and often get confused when encountering such scenarios. The reason for this confusion is mainly because of not being able to find a test case that fails the greedy solution. I also understand that constraints are important in analyzing the type of problem and the first thing I do is analyze the time complexity of the dp solution. Then I think of a greedy solution. But most of the time, I fail to optimize my dp solution or believe it to be a greedy problem and receive a TLE or WA respectively. Hence, I need your help here.

  3. How do you all stay motivated, especially in a scenario where your past 5-10 contests have gone bad? I am currently going through it. I have no aim whatsoever regarding my rating but my only aim is to be able to solve 4-5 problems (Div2A — D) in a contest as fast as I can and increase this count with time. But for the past few contests, I was either able to solve 4 problems but I was comparatively late (compared to my peers) or I solved fewer problems that too after a series of WAs and TLEs. What do you do in such conditions?

  4. Do you keep an eye on standings? I understand looking at the dashboard at regular intervals, as there can be a problem with increasing submissions ahead of what I am trying to solve (like contest #643 where D was easier than C). But do you look at the standings? My general protocol is to look at the standings after I solve 3 problems. This usually tells me how fast I should be to solve the fourth problem (again, compared to my peers).

  5. Do you read all problem statements before attempting one? If yes, how are you able to think of a solution/idea immediately to rate a problem easy or difficult? I have seen many people practicing this and I do not understand how they do it. For example, consider contest #643 again. There must be a few people who read D and attempted D before C. This led others to think that maybe D is easier than C and hence the chain. But how do I identify such things? If tomorrow the submissions are invisible, how should I check if the problem ahead of the current problem was easier than it should be at that hierarchy?

I request you all to answer as honestly as possible, even if it means throwing hard truth directly on my face. A very big thank you to all and to MikeMirzayanov for this platform.

Full text and comments »

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

By IngaleAnkur10, history, 6 years ago, In English

I tried this problem: https://mirror.codeforces.com/contest/1136/problem/D.
And came up with a solution similar to the solution in the editorial.
But I first submitted my Python code in both Python3 and PyPy3 and had TLE.
But when I submitted an ALMOST equivalent code in C++, it got accepted.
I wonder what's wrong in my python code or is it the compiler's/interpreter's doing?

Python Code 1 : https://mirror.codeforces.com/contest/1136/submission/51256343.
Python Code 2 : https://mirror.codeforces.com/contest/1136/submission/51262124.
C++ code: https://mirror.codeforces.com/contest/1136/submission/51257855.

Thanks in advance.

Full text and comments »

  • Vote: I like it
  • -6
  • Vote: I do not like it