Do not start writing code until you understand the 'problem'!
25 Jan, 2024 |
2 mins read
Most of the Junior developers fall for this trap. They want to execute faster and show their skill. It's easier to think, "let's start writing code and we'll figure out the details along the way". But it's a pathway to hell and you along with the whole team will suffer due to this.
If you don't understand the problem scenario properly, you'll definitely make a lot of wrong 'assumptions' and will create a lot of 'tech debts' for sure. Maybe you’re halfway through the implementation and find out that the whole solution approach was wrong since the beginning because you didn’t consider the whole scenario.
As software engineers, our first responsibility is to 'think', 'ask for clarification' if needed, and then 'figure out a solution' based on that.
The time you spend thinking and clarifying now will save more time later.
So, how should you proceed?
Do the proper requirement analysis
Understand ‘why’ we’re doing this
Ask questions if something isn’t clear
Share your idea or design diagrams early on to get feedback
Break your task into smaller sub-tasks
Work on sub-tasks, get reviews faster, and move to the complete solution
Don’t try to make it perfect. First, make it work, then you’ll be able to make it better.