If you prefer a YouTube video, I'm going to give you a video I made on the subject of competitive programming.
I've been doing competitive programming for a while now.
So, let's go through all the steps to get started with competitive programming.
Step 1: Learn a Language
You should first learn a programming language such as C++ or Python. It will be good if you pick C++. What we should learn in basics of language includes
- What are identifiers? How to declare variables.
- How an if ... else statement works.
- How to declare a function in any programming language you choose.
- How to declare loops as for or while loops.
- What is an array? How to declare an array. How to work with strings and concepts like how to concatenate it.
You can refer to a youtube channel for learning all the basics such as:
Step 2: Practice basic questions on programming sites
You can use three programming sites to practice some basic problems including:
- Hackerrank - You can use this programming website to practice some basic questions in your chosen language.
- Hackerearth - This is also a great programming site to practice some basic questions about programming languages. Go directly to the basic problems section and start solving questions.
- Codechef - Go to the practice section on the codechef website. Once you get there, select the beginner section and start problem solving.
Your goal in this step should be to master the language you choose to do competitive programming.
Do not attempt to practise problems from all of the programming sites mentioned above. You must solve 75-100 questions from any one of them.
Step 3: Get started with data structure and algorithm
Once you are done with the basic language problem you will gain little confidence.It is the right time to take a look at a course on data structures and algorithms.
Try to take a good course on data structure and algorithms.
- I am mentioning a good course that is available on YouTube: MIT OpenCourseWare .This course will teach you the basic algorithms necessary to begin competitive programming.
How you should be taking this course.
- Don't just watch all the lectures at once.
- Once you see a lecture, take a look at the site mentioned above. Select that topic and solve some questions on that topic.
- In this way, you will become confident in the subject you attended the lecture.
- Don't try to solve too many questions, only 5-6 questions are enough. Otherwise, you will be stuck at this stage because a lot of questions require multiple concepts, therefore these questions will cost you time.
Step 4: Programming contest time
Once you are done with all the topics at the MIT OpenCourseWare lectures. You are now ready to start a competitive coding journey.
Learning through a live programming contest is always fun.
I am assuming so far that you have not done any of the programming contests till this point.
- You should start first with a long codechef contest.
- Don't wait for long contests to take place as questions from these challenges are always available. Go straight to google and type in the long contents of codechef since November 2017 and start solving from there.
Once you understand how online challenges work, you should start participating in different contests that happen on different websites.
Here's another great website you should check out for more competitions- Codeforces
Codeforces has many archived programming contents and some of the best coders compete on this website. You can also participate in previous competitions that have happened and can get the rank accordingly. Keep participating.
Step 5: Secret to being good at programming competition
The only way to be good at programming competitions is to keep practicing.
Practice! Practice! and practice a lot.
How not to lose the dedication while going up and down during the journey of programming competition
- Find some people who also love problem solving.
- Once you make friends with people who also love to do programming competitions. In this way, you will spend more time with a group of people who are also on your same path.
- You can also discuss many problems with that group of people and become a good day-to-day programmer.
Be Consistent with programming competition and problem solving. If you are consistent, you will definitely see the good result.
Let me clear some doubt about competitive programming which people generally have.
Doubt 1: How long will it take me to be a 5-star coder or a 6-star coder in codechef or how long will it take to turn purple in codeforces?
The answer to this question is very subjective.
- Once you start with competitive programming and start picking up concepts well, then it totally depends on how many hours you are spending on competitive programming.
- Consistency also matters a lot.
Doubt 2 : Is competitive programming the only way to get into a faang company like Facebook, Amazon, Apple, Netflix, Google, or a similar type of product-based company?
To answer this question in one word, it will be a BIG NO.
- I know few people who were selected in these companies, but they never did any competitive programming.
- They were noticed by some of these companies because of their project work that they did. But they also had a good command of basic data structure and algorithms
which helped them to clear the interviews.
Therefore, it always helps to be a competitive programmer and clear these kinds of interviews.
Doubt 3: I have been doing competitive programming for almost 3 months and my friend started just 1 months ago and can solve 3-4 problems in codechef contests whereas I can solve only 1-2 questions. Isn't competitive programming for me?
- Always remember this point in competitive programming that I am about to tell. Never compare yourself to others in competitive programming.
- Especially if you are a beginner in this field. If you start comparing yourself to others, you will spend your days depressed. Ultimately, it will start to depress you, which is not why we start competitive programming.
All of these points must be remembered before competitive programming begins; otherwise, you will be stuck at many points during the incredible journey that is about to begin.
Further reading:
I suggest you to put some other pages like privacy policy, disclaimer,terms and condition and your contact information to increase traffic on your blog.
ReplyDelete