Let me introduce competitive programming

Let me introduce competitive  programming



Hello ! 

I am Priyanka, currently working as System Engineer in GMOリサーチ株式会社. It has been almost 3 years since I’ve started working and writing codes for real products in this company. You can say that I am still in my learning phase as an engineer. I like to achieve new things and always have a mindset to continue growing, so I find ways to improve my skills.

Reason to choose this topic

Have you ever felt that you want to compete with the world ? Want to know more about the level of your own programming skills ? 

Well, we all kind of want to know our strengths and weaknesses to perfect any field, be it personal or professional. In case of testing and comparing your skills the best way is – Competitive programming.  

“Compete the world, show what you got” 

What is competitive programming ?

I will say that it basically trains your mind and teaches you how to think. With my job as a System Engineer, I have experienced that even after shutting my computer after work sometimes I keep on thinking about programming stuff or code I have written in my project and I know you might have also experienced the same. I have realised that once you start doing programming you learn how to code and also learn the “art of thinking”, this can be done using different methods to solve your problem and use creativity with logic to come with a solution by thinking of the problem from different angles.

I compare programming with chess as writing code is an exercise for your brain, same as chess – a mental sport. And when this metal sport is done on the internet, it takes the name of Competitive programming. The main goal of these competitive programming is the same, To prepare a programmer such that his/her logical ability increases and he/she is able to write code for the challenging situation.

Ways for competitive programming 

These are few ways that I have found useful in my case

  1. Understand the concert of Time and complexity 
  2. Choose your favorite programming language
  3. Learn about Data structures
  4. Choose one of online coding platform 
  5. Do it regularly 

(1) Understand the concert of Time and complexity 

Sometimes, you face a problem that may have many possible solutions and choose any one way to solve it without giving much thought on time taken by your solution, this will result in a slow process of your program and you have to change your solution for a faster process. I’ve faced the same problem many times to improve old code. 

The best way to solve any problem is to choose an optimal solution and that’s decided by how much time and space an algorithm takes. So it’s really important to learn about these two concepts to write an optimal solution for the problem.

(2) Choose your favorite programming language

To get achievements with competitive programming, you have to first choose one programming language you are most comfortable with . If you are a beginner you can start with python because it’s easy to learn and syntax are user-friendly. I personally like to use C++ and Python for my challenges based on my comfort with these programming languages. If you have checked out any online competitive programming sites, then you must have noticed that most of the users use C++/Java as these two languages are quite popular among programmers due to being faster than other programming languages. 

(3) Learn about Data structures

If you want to get a feel of a real programmer then the most basic and important thing is to learn about Data structures and algorithms. You must have an understanding of DSA to think about what to apply, where to apply, and when to apply during your problem solving. DSA  consists of Array, Linked List, Stack, Queue, Graph, Tree, Sorting, Recursion, Trie, Dynamic Programming etc. So, basically we should know how to make a perfect combination of Data structures for an algorithm.  

(4) Choose one of online coding platform 

Now, when we come to this stage you know a programming language, know about Time and space complexity and understand Data structures and algorithms. Next step is to try your skills on an online competitive platform. I have worked on a few online competitive programming platforms. Let me introduce you to some.

  1. TopCoder : TopCoder is one of the original platforms for competitive programming online. It provides a list of algorithmic challenges from the past that you can complete on your own directly online using their code editor. Their popular Single Round Matches are offered a few times per month at a specific time where you compete against others to solve challenges the fastest with the best score.
  2. HackerRank :  I used this platform to level up my skills during my college days. Also, the same platform was test programming skills of new graduates (software engineers). HackerRank provides challenges for several different domains such as Algorithms, Mathematics, SQL, Functional Programming, AI, and more. You can solve all the challenges directly online. HackerRank also provides the ability for users to submit applications and apply to jobs by solving company-sponsored coding challenges.
  3.  CodeChef : This site provides challenges for different levels of difficulties. CodeChef is an Indian-based competitive programming website that provides hundreds of challenges. You are able to write code in their online editor and view a collection of challenges that are separated into different categories depending on your skill level. And based on my experience this site has quite difficult challenges that will train your mind for expert level programming.

(5) Do it regularly

To become a good competitive programmer, your dedication, patience, and consistency are very important. The important thing is to practice the coding questions every single day on these platforms regularly. You have to make a routine and try to not break from it once you start. There might be many problems that you will find quite difficult and want to quit doing it but stick on it and find a solution no matter what. It is a platform where you learn by using your skills and also learn from other programmers by competing with them. After a certain time of practice you will naturally be able to choose and optimise algorithms and Data structures for your code. Patience will make you a great programmer ahead and you will learn to love code more and more.

Patience makes life and job Perfect