Lately I have been coming across posts and questions on the forums asking how to learn programming quickly.
This question is pretty vague but shows an intent that the person is looking for guidance on how to start on a path to becoming a software developer that would probably become a full-time career.
And if that is the case then I would recommend you to start with any programming language (doesn’t really matter if you are young and just starting out) and start with the sorting algorithms right away… specifically Selection Sort.
I visit sorting algorithms occasionally. It helps me get in touch with computer science’s data structures and algorithm side quickly. Also, it helps to think logically. Sorting algorithms are a place to refresh your logics. And I like to start with Selection Sort. Now many of you may ask why not Bubble sort and my reply to that is – bubble sort is very trivial and easy. You just need a nested loop and a swap method. It won’t help you much. But if you are a newbie then by all means start from there. Bubble sort is quite easy to understand and implement… and a good way to start your journey.
There are more than one way to implement the logic
This is another important thing. When you read about the selection sort. Do not jump to the implementation part directly. First, understand how it works in theory and they try to implement it by yourself. Remember, there is more than one way to implement the logic. You can come up with your own logic. It might not be very optimized or it could be. But whatever it is – first try to solve it by yourself.
And once you have implemented it (or not) then look for the solution in the book.
By doing this, you are forcing yourself to think about the solution. And that’s the fastest way to get going. Let your brain work for the solution. Spoon feeding the solution is not gonna work for long. Always try by yourself first. And try unless you run out of all the ideas. It takes time, but that’s a one-time thing. If you invest the time into it at the start, it would become much simpler for you later on with the advanced algorithms.
And this has been my experience. It is a tedious process but once you stick up to it, you starts to enjoy the process. And that’s all that matters.
I will continue writing on the same subject every week.
Till then you can perfect selection sort at least.
Oh, I almost forgot, I have started a youtube channel where I’m trying to get back in the groove. That’s because it has been a long time for me that I have not touched the data structures and algorithms and wanted to get started on them again. And as I said, sorting algorithms are the best way to start. So you can join me on this journey via youtube ~ The Innocode.