What are some bad programming practices every programmer needs to be aware of in order to avoid them? originally appeared on Quora: the knowledge sharing network where compelling questions are answered by people with unique insights.
Don’t cling onto the insecure feeling that you have to know everything. You don’t. And that’s ok.
If you spend most of your day in meetings, you should consider spending your time more productively.
The best developers are willing to have an open and straightforward conversation about the code they’ve written and how it can be improved.source
Too many programmers get so close to a solution, only to give up right before they’re about to solve the problem.
By going through the process of articulating your problem to someone else, you’ll often discover the solution. This is what is known at “rubber duck debugging.”source
The most valuable developer is the one who takes ownership and responsibility for the code they write.
In most situations, the performance advantage gained from fully optimizing code to the point that it’s difficult to understand is not worth it.
One of the best ways to learn and grow as a developer is to pair program with developers who have more experience than you. Go seek out other people’s opinions.source
There are some situations where performance is a big issue, such as problems with:
You are hired to write code. But you need to be able to interact with other members of the team, too.
Sometimes, other development teams will make decisions that you think are incorrect. But as long as you can accomplish your team’s objectives, it’s best to simply work around other teams’ quirks, rather than fighting them too hard.source
When you operate in a scenario where users cannot use the product, there is a ton of pressure. You need to develop the ability to stay calm and get the job done.
In the real world, there are trade-offs based on things like:
Don’t create confusing solutions to easy issues.
Too many developers don’t know how to manage other people. You should be the person who other devs turn to for guidance and direction- not just step-by-step instructions.source
Stop making decisions based on “it’s what I know.” You need to be open to using different technologies, languages, and frameworks.
Google is one of the most powerful tools in a programmer’s toolbelt.
Since you’ll spend a large number of hours using things like text editors, the command line, and other tools to write code, it’s essential to master them. Take the time to learn the tips and tricks that make you more efficient.
Code errors happen frequently. They also generally include very valuable information about what went wrong, why it happened, and what lines of triggered the problems. You should seek out error messages, rather than try to avoid them.
The best developers enjoy the time they spend writing code and find themselves getting lost in the in it. It’s not like something will change after you code for 10,000 hours.
This is counterproductive. When mistakes happen, just zoom out and understand these three things:
Know that spending three days to write the wrong solution will teach you more falling victim to analysis paralysis.
Some developers love the text editor known as vim. Others hate it and love the text editor known as emacs. But there will be scenarios where it makes sense to use one over the other
There are programming communities all over the place. With organizations like Railsbridge, Girl Develop Itand events like RubyConf, RailsConf and much more, there’s so much to discover.
The creators of massive open source projects, like ruby, rails, JavaScript, and other tools, are present on Twitter. Spending time here can give you a glimpse into the minds of the people who design the software that you use.source