Live data from Hacker News

What is the most effective thing you did to improve your programming skills?

stackoverflow.com

61–70 of 95 posts

Re: What is the most effective thing you did to improve your programming skills?

#61
I build apps, quite a number of them. And force myself to push every single one of them to completion (launched and deployed).

Every app must have at least 1 non-monetary gains for myself. Examples:

* When I build an app with Tornado, it's because I want to see how event driven server works and how to interact with epoll.

* When I build an app with Rails, it's because I want to experiment with things I probably won't do for professional rails work. E.g. using Rubinius or Erubis.

* One of the older app I killed was written in Zend framework because CakePHP was (a while back) too slow and I think modularity in PHP app is a good thing.

* The latest one is being written in Lua because I have heard so much awesomeness about its JIT.

* With every single app that stays running, I continually learn something new about Ubuntu administration and jQuery plugins.

Of course I killed my apps if they don't take off because VPS renting gets expensive fast.

Re: What is the most effective thing you did to improve your programming skills?

#64
post #15
post #9

For me, they are: * become more sensitive to your daily pain points and move to eradicate them * read other people's code * before sitting down to build anything, think: "is there an easier way to solve it? * learn about good architecture and engineering practices, but don't worry about them until a) you know what you're building b) they're a problem. * learn programming languages in different programming paradigms.

Your idea about tracking daily pain points was the most important thing I ever did, as well-- sort of. I tracked, over a one year period, every single defect that made it into production that I had to correct. I did this at the inspiration of a book on continuous improvement I read. I analyzed the underlying causes of the defects, organized them by category, made Pareto charts, and looked at my underlying procedures…

"I tracked, over a one year period, every single defect that made it into production that I had to correct. I did this at the inspiration of a book on continuous improvement I read."

Which book?

Re: What is the most effective thing you did to improve your programming skills?

#65
post #11

I wrote build scripts for my projects that tracked: 1. Syntax errors on compile (it was C). 2. Test failures. 3. Time of the run. 4. Lines of code. Then I used R to create graphs and reports that were generated periodically. About once an hour I'd go look at them and see what synax+failure levels were per line of code at that time. I'd then plot this as a run chart and start trying to find causes of my high defect in…

Has anyone made a plugin or anything of that sort which abstracts away the grunt work of using this sort of system? It sounds like a great thing to try out were it not for the opportunity cost of trying it.

Not that I know of. I imagine emacs or vim has good error-line parsing which you could steal/copy and get really good results. You could then extend it to work on any language you wanted.

Biggest thing I couldn't get right was automatically connecting frequency of errors to particular lines or modules. I found that I made the same mistakes over and over, and I had to just spot them and jot down what not to do or think of a ninja way to avoid it. I also found that there was a strong correlation between syntax/test failures while writing code and how bad the code was.

What would have helped is if I could calculate the stats per function, line, or file and then have some pattern analysis spit out common grammatical structures that I do which are correlated with errors. It'd be something like:

function/while/if/return 24% chance of defect found in blah.c:func1 and blah.c:func2

Then it'd get closer to predicting defects and letting me go check the spots it recommends.

But, never got around to it since it became really insane after a year already without that level of analysis.

Re: What is the most effective thing you did to improve your programming skills?

#66
post #33
post #11

I wrote build scripts for my projects that tracked: 1. Syntax errors on compile (it was C). 2. Test failures. 3. Time of the run. 4. Lines of code. Then I used R to create graphs and reports that were generated periodically. About once an hour I'd go look at them and see what synax+failure levels were per line of code at that time. I'd then plot this as a run chart and start trying to find causes of my high defect in…

Have you tried delta debugging? http://en.wikipedia.org/wiki/Delta_Debugging

Yes, I have. We used to call it "debugging", but I guess everything has to have a name before the cool kids will use it.

However, this wasn't about find a bug but preventing defects by using evidence to retrain my behavior. The approach is to assume nothing, then use simple graphs and data to look for places where you can change how you do stuff to improve your code. It's not hard, just really tedious.

Re: What is the most effective thing you did to improve your programming skills?

#68
post #50

I wrote a framework. Instead of thinking, "How do I want this program to work?" I had to think, "How do I want every program to work?" Instead of organizing this data, I had to organize any data. Instead of worrying about what my customer needed, I had to worry about what to put in my toolbox before I called on that customer. Instead of handling the current outlying case, I had to learn to anticipate possible outlyin…

Big design up front? Seems like a lot of your advice flies in the face of prevailing agile principles. What do you think about YAGNI? http://bit.ly/cpbljR (YAGNI Wikipedia article -- apparently HN doesn't like apostrophes in urls.)

[deleted]

Re: What is the most effective thing you did to improve your programming skills?

#69
post #50

I wrote a framework. Instead of thinking, "How do I want this program to work?" I had to think, "How do I want every program to work?" Instead of organizing this data, I had to organize any data. Instead of worrying about what my customer needed, I had to worry about what to put in my toolbox before I called on that customer. Instead of handling the current outlying case, I had to learn to anticipate possible outlyin…

Big design up front? Seems like a lot of your advice flies in the face of prevailing agile principles. What do you think about YAGNI? http://bit.ly/cpbljR (YAGNI Wikipedia article -- apparently HN doesn't like apostrophes in urls.)

He's said shit all about how well the framework answered the problem he had. He might not have even had a problem. He just said writing a framework is the most effective thing he has done to improve his programming skills.

Re: What is the most effective thing you did to improve your programming skills?

#70
My first paying programming job was adding peer-to-peer multiplayer to an already fairly mature game that was not designed for it. This gave me a LOT of experience debugging other people's code. That style of multiplayer, common in RTS games, requires every computer to run the same calculations in lockstep. This particular code base had complex AI... with a surprising number of uninitialized variables. I guess it wasn't THAT bad looking back, but tracking them all down took me months, and I learned a lot about developing and debugging large projects in the process.

(The game was Close Combat, if anyone was going to ask)

Post reply on HN