DEV Community


Discussion on: Why you should do Competitive Programming, even if a little

rrampage profile image
Raunak Ramakrishnan

Hi Avi,

I agree with many of your points. Here are my thoughts on the same:

  1. Competitive coding improves one kind of thinking namely that of formulating algorithms where the problem statement is static. Most business tasks are more of getting data from multiple sources, combining them according to domain specific rules and handling various types of failure cases. Competitive programming does not help in this case.
  2. One plus about learning competitive coding is that you learn the standard library of your language very well in order to complete some tasks with minimal fuss. It also makes you dig deeper into the documentation to see why a particular function or structure is slow.
  3. It is one way of improving your perseverance. Coding is all about learning from failure. Trying repeatedly to pass the question hardens you to compile and runtime errors and improves your debugging skills.
  4. On the flip side, you must be careful about writing 1 letter variables and cryptic functions in production because unlike competitive coding where you are the only consumer of your code, your whole team depends on your code.
aviaryan profile image
Avi Aryan Author

Agreed! I am not saying Competitive Programming is all you need, but it's something you should have an idea of. Carrying some CP experience into real-world programming helps.