News for hackers. Stuff that matters.
Re:Ask HN: Why do I always waste time on the weekends? by oz on Monday June 14, 2010 @12:48PM (#1430172)
"I have struggled with this problem for all of my academic and professional career. It was only until this year until I finally started addressing it. After a lot of thought and reading, I've found that I procrastinate for the following reasons:

1) The task is mundane or repetitive.

2) I think the task is trivial. "Oh, thats something I can bang out in a few hours, and I've got all week to work on it"

3) There is a tricky problem within the task that I haven't figured out yet."

You've nailed it, especially number 3. I'll take out my pencil & paper, start sketching out things. The moment something stumps me, I put it down and get up 'for a drink of water.' While I'm up, might as well see what's on USA. Maybe White Collar or Burn Notice...and three hours pass.

If I may ask, how old are you? And why are you 'angry'

Re:Ask HN: Why do I always waste time on the weekends? by angrycoder on Monday June 14, 2010 @01:22PM (#1430286)
If you are getting stuck with number 3, the best thing I've found is to just start coding the problem in isolation. You are probably trying to jump from zero to the most elegant solution. Solve the simplest case first, in the simplest way possible. Throw all your OOD/Design Pattern/Best Practices knowledge out the window, and just solve the simplest case. From there, solve the next case, and the next one, eventually you will start to see the pattern, and the correct abstraction. From there, you can derive the elegant solution that fits all cases.

That is the problem with most solutions you find printed in books or on the web. They only show the problem and the fully refactored solution. Refactored solutions, even when fully explained, are just another form of obfuscation. Behind every tough problem, there are notebooks and whiteboards and hundreds/thousands of lines of discarded code that you never see. That is where the magic happens. You just have to do the work, you have to make your own ah-ha! moment.

This process is a lot easier if you use a language that has a REPL - like python, ruby, or the various lisp dialects. It is easier to work through problems this way, regardless of what your final target language may be.

Re:Ask HN: Why do I always waste time on the weekends? by oz on Monday June 14, 2010 @04:29PM (#1430867)
"You are probably trying to jump from zero to the most elegant solution."

Oh god, yes. I realized recently that in practice, it's not done that way. Hard habit to break, though. I used to think that being smart meant that solutions were obvious.

Re:Ask HN: Why do I always waste time on the weekends? by aristoxenus on Monday June 14, 2010 @04:40PM (#1430910)
Man, you need to get rid of that TV! There are plenty of ways to procrastinate in the world, but that one must have the lowest "value added to life"-vs-"time utterly wasted" ratio of them all.
Re:Ask HN: Why do I always waste time on the weekends? by oz on Monday June 14, 2010 @04:57PM (#1430950)
I can't. It's my sister's.

I want to get my own place in the next couple of months.