Live data from Hacker News

Ask HN: What habits make a programmer great?

news.ycombinator.com

131–140 of 191 posts

Re: Ask HN: What habits make a programmer great?

#131
post #125

1. Embrace the grind. Motivation comes and goes, but the grind remains. This doesn't mean working all day every day, but rather setting aside specific blocks of time and doing the same thing every single day. Workouts should happen at the same time every day. Work should happen at the same time every day. Each of these things should be daily habits and doing them at the same time every day helps them become habits. 2…

> Drop TV, Porn, news, music and video games.

No fun allowed then?

Re: Ask HN: What habits make a programmer great?

#132
Make it easy to verify what you have written works. This can be done in several ways, and which ones to use depends on the people you're working with and what access to the production code you have. Debug log levels are a popular way to do this.

* Always make a way to examine the data that's coming in (over network, arguments, whatever) to make sure your code is receiving the input it expects, and to be able to predict output/state changes.

* Similarly, have a way to see the data/state changes produced by what you wrote.

* Don't log all this by default.

* ...except for unexpected outcomes. By all means, check your inputs and loudly complain if they are garbage in a way that's unrecoverable.

* Be judicious about how much of this you normally expose to a user; don't overwhelm a user with unactionable noise.

Re: Ask HN: What habits make a programmer great?

#133

Hard to say any definite habits that work for everyone, as each person is so different, but just for the fun of it, I'll try to list habits that work for me: * Keep a diary. Write out problems and solution propositions first, if the solution is not trivial. * Keep your mind clean, always finish what you started, so you can have completion and not clutter your thought process. This means not leaving code in a state of…

One way I started to look at KISS is that there are so many ways for software to be complex on higher architectural level, that there is absolutely no reason to make your life harder and go for implementing complex solutions on low level. Get it to a point where it's simple, the complexity will come later.

Re: Ask HN: What habits make a programmer great?

#134
post #125

1. Embrace the grind. Motivation comes and goes, but the grind remains. This doesn't mean working all day every day, but rather setting aside specific blocks of time and doing the same thing every single day. Workouts should happen at the same time every day. Work should happen at the same time every day. Each of these things should be daily habits and doing them at the same time every day helps them become habits. 2…

> Drop TV, Porn, news, music and video games. No fun allowed then?

Active things. Go for a hike, play frisbee, walk the dog, play piano or guitar or whatever floats your boat. The whole point is to work for your rewards instead of getting them instantly at the push of a button.

Re: Ask HN: What habits make a programmer great?

#135
A bad habit of mine is jumping into a problem and trying to get a final & complete solution first time.

This means that I often get bogged down in the finer details and corner-cases before even the most significant functionality is complete because I am trying to deliver a gold-plated, perfect, thought-of-everything solution the first time.

I've found time and time again that it really helps to take a step back, acknowledge to yourself and/or others that there will be TODOs, and start building up the core functionality piece-by-piece starting from the fundamentals and working your way up to the details & corner-cases.

That might mean you play around with a few approaches for an hour, pick one and then commit once, or it might mean that you go through many refactorings and commits over a period of days or weeks.

Whatever approach you take, I've found the feel-good factor/reassurance of having working-code but with known TODOs really helps keep me going and avoids me getting irritated/burnt-out fighting with problems before I've got anything working.

It is not going to be perfect first time, but "mighty oaks from little acorns grow" as they say.

tl;dr - get the fundamentals working first, refactor later to handle the edge-cases or make it sophisticated/elegant.

Re: Ask HN: What habits make a programmer great?

#137
Something more habit-like that I am still trying to cultivate: log what you do. It's really useful to be able to look up what you did when. It helps with reviews/invoices, and it helps you get better at estimating how long it takes you to do things, which is essential.

Re: Ask HN: What habits make a programmer great?

#138
post #125

1. Embrace the grind. Motivation comes and goes, but the grind remains. This doesn't mean working all day every day, but rather setting aside specific blocks of time and doing the same thing every single day. Workouts should happen at the same time every day. Work should happen at the same time every day. Each of these things should be daily habits and doing them at the same time every day helps them become habits. 2…

Is this a live to code philosophy?

Re: Ask HN: What habits make a programmer great?

#139
post #125

1. Embrace the grind. Motivation comes and goes, but the grind remains. This doesn't mean working all day every day, but rather setting aside specific blocks of time and doing the same thing every single day. Workouts should happen at the same time every day. Work should happen at the same time every day. Each of these things should be daily habits and doing them at the same time every day helps them become habits. 2…

Can you elaborate on point 3 ( Music part).

Recorded music is great. I listen to recorded music all the time when I'm at the gym or at the office. I use it to set the mood. I use it to fill the silence. I use it to block out office noise. But here's the big question: could you go a week without listening to any recorded music at all? You'd be surprised how many people try to stop and find themselves feeling symptoms of withdrawal. That implies some form of psychological addiction, which in turn robs motivation.

The whole point of point 3 is to work for your rewards instead of getting them instantly at the push of a button. It's too easy to get addicted to the latter and with any kind of addiction comes a decrease in motivation.

Re: Ask HN: What habits make a programmer great?

#140

Meta-habit: learn to adopt different habits for different situations. With that in mind, some techniques I've found useful for various situations: "Researchey" green-field development for data-science-like problems: 1. If it can be done manually first, do it manually. You'll gain an intuition for how you might approach it. 2. Collect examples. Start with a spreadsheet of data that highlights the data you have availab…

Thanks for these notes!

I reformatted this in a Google Doc, if anybody wants: https://docs.google.com/document/d/1Pix3-l3Qz1aLOuxoiiP1PTV6...

Post reply on HN